AllowContentAttribute Class

AllowContentAttribute Class

Indicates which content view models are allowed to be added to this property.

[AttributeUsage(AttributeTargets.Property, AllowMultiple = true)]
public sealed class AllowContentAttribute: Attribute, IPropertyModelAttribute

Inheritance  Attribute AllowContentAttribute

Implements  IPropertyModelAttribute

Constructors

Name Description
AllowContentAttribute(Type[]) Default constructor.

Properties

Name Description
ContentModelTypes Gets or sets the content model types that content in this section or property must have. Types must implement the IContentModel interface.

Methods

Name Description
Apply(PropertyDefinition) Applies this attribute's settings to the definition model. Automatically called by the Redakt system on startup.