Search Results for

    Show / Hide Table of Contents
    View Source

    Struct ReadOnlyContentBaseAdapter

    Provides a read-only adapter for IContentBase instances.

    Namespace: Umbraco.Cms.Core.Models
    Assembly: Umbraco.Core.dll
    Syntax
    public struct ReadOnlyContentBaseAdapter : IReadOnlyContentBase
    Remarks

    This struct wraps an IContentBase instance and exposes its properties through the IReadOnlyContentBase interface without allowing modifications.

    Properties

    View Source

    ContentTypeId

    Gets the content type id

    Declaration
    public int ContentTypeId { get; }
    Property Value
    Type Description
    int
    View Source

    CreateDate

    Gets the creation date.

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

    CreatorId

    Gets the identifier of the user who created this entity.

    Declaration
    public int CreatorId { get; }
    Property Value
    Type Description
    int
    View Source

    Id

    Gets the integer identifier of the entity.

    Declaration
    public int Id { get; }
    Property Value
    Type Description
    int
    View Source

    Key

    Gets the Guid unique identifier of the entity.

    Declaration
    public Guid Key { get; }
    Property Value
    Type Description
    Guid
    View Source

    Level

    Gets the level of the entity.

    Declaration
    public int Level { get; }
    Property Value
    Type Description
    int
    View Source

    Name

    Gets the name of the entity.

    Declaration
    public string? Name { get; }
    Property Value
    Type Description
    string
    View Source

    ParentId

    Gets the identifier of the parent entity.

    Declaration
    public int ParentId { get; }
    Property Value
    Type Description
    int
    View Source

    Path

    Gets the path to the entity.

    Declaration
    public string Path { get; }
    Property Value
    Type Description
    string
    View Source

    SortOrder

    Gets the sort order of the entity.

    Declaration
    public int SortOrder { get; }
    Property Value
    Type Description
    int
    View Source

    UpdateDate

    Gets the last update date.

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

    VersionId

    Gets the version identifier.

    Declaration
    public int VersionId { get; }
    Property Value
    Type Description
    int
    View Source

    WriterId

    Gets the identifier of the writer.

    Declaration
    public int WriterId { get; }
    Property Value
    Type Description
    int

    Methods

    View Source

    Create(IContentBase)

    Creates a new ReadOnlyContentBaseAdapter instance from an IContentBase.

    Declaration
    public static ReadOnlyContentBaseAdapter Create(IContentBase content)
    Parameters
    Type Name Description
    IContentBase content

    The content base to wrap.

    Returns
    Type Description
    ReadOnlyContentBaseAdapter

    A read-only adapter for the specified content.

    • View Source
    In this article
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX