Search Results for

    Show / Hide Table of Contents
    View Source

    Class UmbracoContext

    Class that encapsulates Umbraco information of a specific HTTP request

    Inheritance
    System.Object
    DisposableObjectSlim
    Namespace: Umbraco.Cms.Web.Common.UmbracoContext
    Assembly: Umbraco.Web.Common.dll
    Syntax
    public class UmbracoContext : DisposableObjectSlim, IUmbracoContext

    Properties

    View Source

    CleanedUmbracoUrl

    Declaration
    public Uri CleanedUmbracoUrl { get; }
    Property Value
    Type Description
    Uri
    View Source

    Content

    Gets the published content cache.

    Declaration
    public IPublishedContentCache Content { get; }
    Property Value
    Type Description
    IPublishedContentCache
    View Source

    Domains

    Gets the domains cache.

    Declaration
    public IDomainCache Domains { get; }
    Property Value
    Type Description
    IDomainCache
    View Source

    InPreviewMode

    Gets a value indicating whether the current user is in a preview mode and browsing the site (ie. not in the admin UI)

    Declaration
    public bool InPreviewMode { get; }
    Property Value
    Type Description
    System.Boolean
    View Source

    IsDebug

    Gets a value indicating whether the request has debugging enabled

    Declaration
    public bool IsDebug { get; }
    Property Value
    Type Description
    System.Boolean

    true if this instance is debug; otherwise, false.

    View Source

    Media

    Gets the published media cache.

    Declaration
    public IPublishedMediaCache Media { get; }
    Property Value
    Type Description
    IPublishedMediaCache
    View Source

    ObjectCreated

    Declaration
    public DateTime ObjectCreated { get; }
    Property Value
    Type Description
    DateTime
    View Source

    OriginalRequestUrl

    Declaration
    public Uri OriginalRequestUrl { get; }
    Property Value
    Type Description
    Uri
    View Source

    PublishedRequest

    Gets or sets the PublishedRequest object

    Declaration
    public IPublishedRequest PublishedRequest { get; set; }
    Property Value
    Type Description
    IPublishedRequest
    View Source

    PublishedSnapshot

    Gets the published snapshot.

    Declaration
    public IPublishedSnapshot PublishedSnapshot { get; }
    Property Value
    Type Description
    IPublishedSnapshot

    Methods

    View Source

    DisposeResources()

    Disposes managed resources

    Declaration
    protected override void DisposeResources()
    View Source

    ForcedPreview(Boolean)

    Declaration
    public IDisposable ForcedPreview(bool preview)
    Parameters
    Type Name Description
    System.Boolean preview
    Returns
    Type Description
    IDisposable
    • Improve this Doc
    • View Source
    In This Article
    • Properties
      • CleanedUmbracoUrl
      • Content
      • Domains
      • InPreviewMode
      • IsDebug
      • Media
      • ObjectCreated
      • OriginalRequestUrl
      • PublishedRequest
      • PublishedSnapshot
    • Methods
      • DisposeResources()
      • ForcedPreview(Boolean)
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX