Represents an abstract class for composition specific ContentType properties and methods
InheritanceSystem.Object
Namespace: Umbraco.Cms.Core.Models Assembly: Umbraco.Core.dll Syntax[DataContract(IsReference = true)]
public abstract class ContentTypeCompositionBase : ContentTypeBase, IContentTypeComposition, IContentTypeBase, IUmbracoEntity, ITreeEntity, IEntity, IDeepCloneable, IRememberBeingDirty, ICanBeDirty
Constructors View Source ContentTypeCompositionBase(IShortStringHelper, Int32) Declaration
protected ContentTypeCompositionBase(IShortStringHelper shortStringHelper, int parentId)
Parameters View Source ContentTypeCompositionBase(IShortStringHelper, IContentTypeComposition) Declaration
protected ContentTypeCompositionBase(IShortStringHelper shortStringHelper, IContentTypeComposition parent)
Parameters View Source ContentTypeCompositionBase(IShortStringHelper, IContentTypeComposition, String) Declaration
protected ContentTypeCompositionBase(IShortStringHelper shortStringHelper, IContentTypeComposition parent, string alias)
Parameters Properties View Source CompositionPropertyGroups
Gets the property groups for the entire composition.
Declaration[IgnoreDataMember]
public IEnumerable<PropertyGroup> CompositionPropertyGroups { get; }
Property Value View Source CompositionPropertyTypes
Gets the property types for the entire composition.
Declaration[IgnoreDataMember]
public IEnumerable<IPropertyType> CompositionPropertyTypes { get; }
Property Value View Source ContentTypeComposition
Gets or sets the content types that compose this content type.
Declaration[DataMember]
public IEnumerable<IContentTypeComposition> ContentTypeComposition { get; set; }
Property Value View Source RemovedContentTypes Declaration
public IEnumerable<int> RemovedContentTypes { get; }
Property Value Type Description IEnumerable<System.Int32> Methods View Source AddContentType(IContentTypeComposition)
Adds a content type to the composition.
Declarationpublic bool AddContentType(IContentTypeComposition contentType)
Parameters Returns Type Description System.Boolean
True if the content type was added, otherwise false.
View Source AddPropertyGroup(String, String)Adds a property group with the specified name
and alias
.
public override 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 the property type to the specified property group (creates a new group if not found and a name is specified).
Declarationpublic override 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
.
Gets a list of ContentType aliases from the current composition
Declarationpublic IEnumerable<string> CompositionAliases()
Returns Type Description IEnumerable<System.String>
An enumerable list of string aliases
View Source CompositionIds()Gets a list of ContentType Ids from the current composition
Declarationpublic IEnumerable<int> CompositionIds()
Returns Type Description IEnumerable<System.Int32>
An enumerable list of integer ids
View Source CompositionKeys()Gets a list of ContentType keys from the current composition
Declarationpublic IEnumerable<Guid> CompositionKeys()
Returns Type Description IEnumerable<Guid>
An enumerable list of integer ids.
View Source ContentTypeCompositionExists(String)Checks if a ContentType with the supplied alias exists in the list of composite ContentTypes
Declarationpublic bool ContentTypeCompositionExists(string alias)
Parameters Type Name Description System.String alias
Alias of a ContentType
Returns Type Description System.BooleanTrue if ContentType with alias exists, otherwise returns False
View Source GetOriginalComposedPropertyTypes()Gets the property types obtained via composition.
Declarationpublic IEnumerable<IPropertyType> GetOriginalComposedPropertyTypes()
Returns View Source PerformDeepClone(Object) Declaration
protected override void PerformDeepClone(object clone)
Parameters Type Name Description System.Object clone View Source PropertyTypeExists(String)
Checks whether a PropertyType with a given alias already exists
Declarationpublic override 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
Removes a content type with a specified key from the composition.
Declarationpublic bool RemoveContentType(Guid key)
Parameters Type Name Description Guid key
The key of the content type to remove.
Returns Type Description System.BooleanTrue if the content type was removed, otherwise false.
View Source RemoveContentType(String)Removes a content type with a specified alias from the composition.
Declarationpublic bool RemoveContentType(string alias)
Parameters Type Name Description System.String alias
The alias of the content type to remove.
Returns Type Description System.BooleanTrue if the content type was removed, otherwise false.
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