Represents an abstract class for base ContentType properties and methods
InheritanceSystem.Object
Namespace: Umbraco.Cms.Core.Models Assembly: Umbraco.Core.dll Syntax[DataContract(IsReference = true)]
public abstract class ContentTypeBase : TreeEntityBase, IContentTypeBase, IUmbracoEntity, ITreeEntity, IEntity, IDeepCloneable, IRememberBeingDirty, ICanBeDirty
Constructors View Source ContentTypeBase(IShortStringHelper, Int32) Declaration
protected ContentTypeBase(IShortStringHelper shortStringHelper, int parentId)
Parameters View Source ContentTypeBase(IShortStringHelper, IContentTypeBase) Declaration
protected ContentTypeBase(IShortStringHelper shortStringHelper, IContentTypeBase parent)
Parameters View Source ContentTypeBase(IShortStringHelper, IContentTypeBase, String) Declaration
protected ContentTypeBase(IShortStringHelper shortStringHelper, IContentTypeBase parent, string alias)
Parameters Properties View Source Alias
The Alias of the ContentType
Declaration[DataMember]
public virtual string Alias { get; set; }
Property Value Type Description System.String View Source AllowedAsRoot
Gets or Sets a boolean indicating whether this ContentType is allowed at the root
Declaration[DataMember]
public bool AllowedAsRoot { get; set; }
Property Value Type Description System.Boolean View Source AllowedContentTypes
Gets or sets a list of integer Ids for allowed ContentTypes
Declaration[DataMember]
public IEnumerable<ContentTypeSort>? AllowedContentTypes { get; set; }
Property Value View Source Description
Description for the ContentType
Declaration[DataMember]
public string Description { get; set; }
Property Value Type Description System.String View Source Icon
Name of the icon (sprite class) used to identify the ContentType
Declaration[DataMember]
public string Icon { get; set; }
Property Value Type Description System.String View Source IsElement
Gets or sets a value indicating whether this content type is for an element.
Declaration[DataMember]
public bool IsElement { get; set; }
Property Value Type Description System.Boolean View Source ListView
Gets or Sets a Guid, which is the key of the listview.
Declaration[DataMember]
public Guid? ListView { get; set; }
Property Value Type Description System.Nullable<Guid> View Source NoGroupPropertyTypes
Gets or sets the local property types that do not belong to a group.
Declarationpublic IEnumerable<IPropertyType> NoGroupPropertyTypes { get; set; }
Property Value View Source PropertyGroups
Gets or sets the local property groups.
Declaration[DataMember]
public PropertyGroupCollection PropertyGroups { get; set; }
Property Value View Source PropertyTypes
Gets all local property types all local property groups or ungrouped.
Declaration[IgnoreDataMember]
public IEnumerable<IPropertyType> PropertyTypes { get; }
Property Value View Source SupportsPublishing
Gets a value indicating whether the content type supports publishing.
Declarationpublic abstract bool SupportsPublishing { get; }
Property Value Type Description System.Boolean View Source Thumbnail
Name of the thumbnail used to identify the ContentType
Declaration[DataMember]
public string Thumbnail { get; set; }
Property Value Type Description System.String View Source Variations
Gets or sets the content variation of the content type.
Declarationpublic virtual ContentVariation Variations { get; set; }
Property Value Methods View Source AddPropertyGroup(String, String)
Adds a property group with the specified name
and alias
.
public abstract bool AddPropertyGroup(string alias, string name)
Parameters Type Name Description System.String alias
The alias.
System.String nameName of the group.
Returns Type Description System.BooleanReturns true
if a property group with specified alias
was added; otherwise, false
.
Adds a PropertyType, which does not belong to a PropertyGroup.
Declarationpublic bool AddPropertyType(IPropertyType propertyType)
Parameters Returns Type Description System.Boolean
Returns True
if PropertyType was added, otherwise False
Adds the property type to the specified property group (creates a new group if not found and a name is specified).
Declarationpublic abstract bool AddPropertyType(IPropertyType propertyType, string propertyGroupAlias, string propertyGroupName = null)
Parameters Type Name Description IPropertyType propertyType
The property type to add.
System.String propertyGroupAliasThe alias of the property group to add the property type to.
System.String propertyGroupNameThe name of the property group to create when not found.
Returns Type Description System.BooleanReturns true
if the property type was added; otherwise, false
.
public ContentTypeBase DeepCloneWithResetIdentities(string alias)
Parameters Type Name Description System.String alias Returns View Source IsDirty()
Indicates whether the current entity is dirty.
Declarationpublic override bool IsDirty()
Returns Type Description System.Boolean
True if entity is dirty, otherwise False
View Source MovePropertyType(String, String)Moves a PropertyType to a specified PropertyGroup
Declarationpublic bool MovePropertyType(string propertyTypeAlias, string propertyGroupAlias)
Parameters Type Name Description System.String propertyTypeAlias
Alias of the PropertyType to move
System.String propertyGroupAliasAlias of the PropertyGroup to move the PropertyType to
Returns Type Description System.Boolean View Source PerformDeepClone(Object) Declarationprotected override void PerformDeepClone(object clone)
Parameters Type Name Description System.Object clone View Source PropertyGroupsChanged(Object, NotifyCollectionChangedEventArgs) Declaration
protected void PropertyGroupsChanged(object sender, NotifyCollectionChangedEventArgs e)
Parameters Type Name Description System.Object sender System.Collections.Specialized.NotifyCollectionChangedEventArgs e View Source PropertyTypeExists(String)
Checks whether a PropertyType with a given alias already exists
Declarationpublic abstract bool PropertyTypeExists(string alias)
Parameters Type Name Description System.String alias
Alias of the PropertyType
Returns Type Description System.BooleanReturns True
if a PropertyType with the passed in alias exists, otherwise False
protected void PropertyTypesChanged(object sender, NotifyCollectionChangedEventArgs e)
Parameters Type Name Description System.Object sender System.Collections.Specialized.NotifyCollectionChangedEventArgs e View Source RemovePropertyGroup(String)
Removes a PropertyGroup from the current ContentType
Declarationpublic void RemovePropertyGroup(string alias)
Parameters Type Name Description System.String alias
Alias of the PropertyGroup to remove
View Source RemovePropertyType(String)Removes a PropertyType from the current ContentType
Declarationpublic void RemovePropertyType(string alias)
Parameters Type Name Description System.String alias
Alias of the IPropertyType to remove
View Source ResetDirtyProperties()Resets dirty properties by clearing the dictionary used to track changes.
Declarationpublic override void ResetDirtyProperties()
View Source SupportsPropertyVariation(String, String, Boolean)
Validates that a combination of culture and segment is valid for the content type properties.
Declarationpublic bool SupportsPropertyVariation(string culture, string segment, bool wildcards = false)
Parameters Type Name Description System.String culture
The culture.
System.String segmentThe segment.
System.Boolean wildcardsA value indicating whether wildcard are supported.
Returns Type Description System.BooleanTrue if the combination is valid; otherwise false.
View Source SupportsVariation(String, String, Boolean)Validates that a combination of culture and segment is valid for the content type.
Declarationpublic bool SupportsVariation(string culture, string segment, bool wildcards = false)
Parameters Type Name Description System.String culture
The culture.
System.String segmentThe segment.
System.Boolean wildcardsA value indicating whether wildcard are supported.
Returns Type Description System.BooleanTrue if the combination is valid; otherwise false.
View Source ToSimple() Declarationpublic abstract ISimpleContentType ToSimple()
Returns
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4