Class UmbracoContextFactory
Creates and manages
Inheritance
System.Object
Namespace: Umbraco.Cms.Web.Common.UmbracoContext
Assembly: Umbraco.Web.Common.dll
Syntax
public class UmbracoContextFactory : IUmbracoContextFactory
Constructors
View SourceUmbracoContextFactory(IUmbracoContextAccessor, IPublishedSnapshotService, UmbracoRequestPaths, IHostingEnvironment, UriUtility, ICookieManager, IHttpContextAccessor)
Initializes a new instance of the UmbracoContextFactory class.
Declaration
public UmbracoContextFactory(IUmbracoContextAccessor umbracoContextAccessor, IPublishedSnapshotService publishedSnapshotService, UmbracoRequestPaths umbracoRequestPaths, IHostingEnvironment hostingEnvironment, UriUtility uriUtility, ICookieManager cookieManager, IHttpContextAccessor httpContextAccessor)
Parameters
Type | Name | Description |
---|---|---|
IUmbracoContextAccessor | umbracoContextAccessor | |
IPublishedSnapshotService | publishedSnapshotService | |
UmbracoRequestPaths | umbracoRequestPaths | |
IHostingEnvironment | hostingEnvironment | |
UriUtility | uriUtility | |
ICookieManager | cookieManager | |
Microsoft.AspNetCore.Http.IHttpContextAccessor | httpContextAccessor |
Methods
View SourceEnsureUmbracoContext()
Declaration
public UmbracoContextReference EnsureUmbracoContext()
Returns
Type | Description |
---|---|
UmbracoContextReference |