Search Results for

    Show / Hide Table of Contents
    View Source

    Class NodeDto

    Represents a data transfer object (DTO) for a node entity in the Umbraco persistence layer. This class is used to transfer node data between the database and application logic.

    Inheritance
    object
    Namespace: Umbraco.Cms.Infrastructure.Persistence.Dtos
    Assembly: Umbraco.Infrastructure.dll
    Syntax
    public class NodeDto

    Constructors

    View Source

    NodeDto()

    Declaration
    public NodeDto()

    Fields

    View Source

    CreateDateColumnName

    Declaration
    public const string CreateDateColumnName = "createDate"
    Field Value
    Type Description
    string
    View Source

    IdColumnName

    This actually represents NodeId but kept as Id for backward compatibility.

    Declaration
    public const string IdColumnName = "id"
    Field Value
    Type Description
    string
    View Source

    KeyColumnName

    Declaration
    public const string KeyColumnName = "uniqueId"
    Field Value
    Type Description
    string
    View Source

    LevelColumnName

    Declaration
    public const string LevelColumnName = "level"
    Field Value
    Type Description
    string
    View Source

    NodeIdSeed

    Declaration
    public const int NodeIdSeed = 1060
    Field Value
    Type Description
    int
    View Source

    NodeObjectTypeColumnName

    Declaration
    public const string NodeObjectTypeColumnName = "nodeObjectType"
    Field Value
    Type Description
    string
    View Source

    ParentIdColumnName

    Declaration
    public const string ParentIdColumnName = "parentId"
    Field Value
    Type Description
    string
    View Source

    PathColumnName

    Declaration
    public const string PathColumnName = "path"
    Field Value
    Type Description
    string
    View Source

    PrimaryKeyColumnName

    Declaration
    public const string PrimaryKeyColumnName = "id"
    Field Value
    Type Description
    string
    View Source

    SortOrderColumnName

    Declaration
    public const string SortOrderColumnName = "sortOrder"
    Field Value
    Type Description
    string
    View Source

    TableName

    Declaration
    public const string TableName = "umbracoNode"
    Field Value
    Type Description
    string
    View Source

    TextColumnName

    Declaration
    public const string TextColumnName = "text"
    Field Value
    Type Description
    string
    View Source

    TrashedColumnName

    Declaration
    public const string TrashedColumnName = "trashed"
    Field Value
    Type Description
    string
    View Source

    UniqueIdColumnNameTypo

    Declaration
    public const string UniqueIdColumnNameTypo = "uniqueID"
    Field Value
    Type Description
    string
    View Source

    UserIdColumnName

    Declaration
    public const string UserIdColumnName = "nodeUser"
    Field Value
    Type Description
    string

    Properties

    View Source

    CreateDate

    Gets or sets the date and time when the node was created.

    Declaration
    [Constraint(Default = SystemMethods.CurrentUTCDateTime)]
    public DateTime CreateDate { get; set; }
    Property Value
    Type Description
    DateTime
    View Source

    Level

    Gets or sets the depth level of the node within the content tree hierarchy, where the root node is level 0.

    Declaration
    [Index(IndexTypes.NonClustered, Name = "IX_umbracoNode_Level", ForColumns = "level,parentId,sortOrder,nodeObjectType,trashed", IncludeColumns = "nodeUser,path,uniqueId,createDate")]
    public short Level { get; set; }
    Property Value
    Type Description
    short
    Remarks

    NOTE: This index is primarily for the nucache data lookup, see https://github.com/umbraco/Umbraco-CMS/pull/8365#issuecomment-673404177

    View Source

    NodeId

    Gets or sets the unique identifier for the node.

    Declaration
    [PrimaryKeyColumn(IdentitySeed = 1060)]
    public int NodeId { get; set; }
    Property Value
    Type Description
    int
    View Source

    NodeObjectType

    Gets or sets the unique identifier (GUID) representing the object type associated with this node.

    Declaration
    [NullSetting(NullSetting = NullSettings.Null)]
    [Index(IndexTypes.NonClustered, Name = "IX_umbracoNode_ObjectType", ForColumns = "nodeObjectType,trashed", IncludeColumns = "uniqueID,parentId,level,path,sortOrder,nodeUser,text,createDate")]
    public Guid? NodeObjectType { get; set; }
    Property Value
    Type Description
    Guid?
    Remarks

    TODO: db rename to 'objectType'

    View Source

    ParentId

    Gets or sets the identifier of the parent node.

    Declaration
    [ForeignKey(typeof(NodeDto))]
    [Index(IndexTypes.NonClustered, Name = "IX_umbracoNode_parentId_nodeObjectType", ForColumns = "parentId,nodeObjectType", IncludeColumns = "trashed,nodeUser,level,path,sortOrder,uniqueID,text,createDate")]
    public int ParentId { get; set; }
    Property Value
    Type Description
    int
    View Source

    Path

    Gets or sets the hierarchical path of the node, typically representing its position within the content tree.

    Declaration
    [Length(150)]
    [Index(IndexTypes.NonClustered, Name = "IX_umbracoNode_Path")]
    public string Path { get; set; }
    Property Value
    Type Description
    string
    View Source

    SortOrder

    Gets or sets the position of the node relative to its siblings for sorting purposes.

    Declaration
    [Index(IndexTypes.NonClustered, Name = "IX_umbracoNode_ObjectType_trashed_sorted", ForColumns = "nodeObjectType,trashed,sortOrder,id", IncludeColumns = "uniqueID,parentId,level,path,nodeUser,text,createDate")]
    public int SortOrder { get; set; }
    Property Value
    Type Description
    int
    View Source

    Text

    Gets or sets the display text or name associated with the node.

    Declaration
    [NullSetting(NullSetting = NullSettings.Null)]
    public string? Text { get; set; }
    Property Value
    Type Description
    string
    View Source

    Trashed

    Gets or sets a value indicating whether this node is in the trash (i.e., marked as deleted but not permanently removed).

    Declaration
    [Constraint(Default = "0")]
    [Index(IndexTypes.NonClustered, Name = "IX_umbracoNode_Trashed")]
    public bool Trashed { get; set; }
    Property Value
    Type Description
    bool
    View Source

    UniqueId

    Gets or sets the globally unique identifier (GUID) that uniquely identifies this node in the database.

    Declaration
    [NullSetting(NullSetting = NullSettings.NotNull)]
    [Index(IndexTypes.UniqueNonClustered, Name = "IX_umbracoNode_UniqueId", IncludeColumns = "parentId,level,path,sortOrder,trashed,nodeUser,text,createDate")]
    [Constraint(Default = SystemMethods.NewGuid)]
    public Guid UniqueId { get; set; }
    Property Value
    Type Description
    Guid
    View Source

    UserId

    Gets or sets the identifier of the user who created the node.

    Declaration
    [ForeignKey(typeof(UserDto))]
    [NullSetting(NullSetting = NullSettings.Null)]
    public int? UserId { get; set; }
    Property Value
    Type Description
    int?
    Remarks

    Returns null if zero. TODO: db rename to 'createUserId'.

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