Nucleus .Net Core CMS

Models.Context Class

Namespace: Nucleus.Abstractions.Models
Assembly: Nucleus.Abstractions.dll
Encapsulates information about the current request.
Get a reference to the Context class by using dependency injection. The class is populated by Nucleus.Core.LayoutPageRoutingMiddleware and Nucleus.Core.LayoutModuleRoutingMiddleware and can be used in extensions.
Represents parameters which are specified at the end of the local (page route) path.
The page route which was matched to find the page.
The module being accessed.
Remarks
This property is set when rendering a module's content and also when an extension route is used to call a module's controller action, or to get the output of a single module only. It is NULL otherwise. For module routes: Module routes contain a "mid" query string value to identify the module by id. This property is set by the ModuleRoutingMiddleware. For module content rendering: This property is set by the ModuleContentRenderer.
The page being accessed.
The site being accessed.
Set (Site site, Page page, PageModule module, LocalPath localPath, PageRoute matchedRoute)
Set the Nucleus context for the current request.
Set (Site site, Page page, PageModule module)
Set the Nucleus context for the current request.
Set (Page page, LocalPath localPath, PageRoute matchedRoute)
Set the Nucleus context for the current request.
Set (Site site)
Set the Nucleus context for the current request.
Parameters
Name Type
site Nucleus.Abstractions.Models.Site
Set (Page page)
Set the Nucleus context for the current request.
Parameters
Name Type
page Nucleus.Abstractions.Models.Page