Class PropertyDefinitionModel
Represents a model of a PropertyDefinition generated from attributes on a property, typically on a typed page.
Inheritance
Inherited Members
Namespace: EPiServer.DataAbstraction.RuntimeModel
Assembly: EPiServer.dll
Version: 11.20.7Syntax
public class PropertyDefinitionModel
Constructors
PropertyDefinitionModel()
Declaration
public PropertyDefinitionModel()
Properties
Attributes
Gets the attributes on the model.
Declaration
public ModelAttributeCollection Attributes { get; }
Property Value
Type | Description |
---|---|
ModelAttributeCollection |
AvailableInEditMode
Gets or sets the if the generated DisplayEditUI should be set.
Declaration
public bool? AvailableInEditMode { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<System.Boolean> | If PropertyDefinition should be available in edit mode |
Remarks
This value is extracted from System.ComponentModel.DataAnnotations.EditableAttribute.AllowEdit
If the nullable does not have a value it means that the attribute was not set.
BackingType
Gets or sets the backing type which should inherit from PropertyData.
Declaration
public Type BackingType { get; set; }
Property Value
Type | Description |
---|---|
System.Type | The type of the backing PropertyData |
CultureSpecific
Gets or sets the if the generated LanguageSpecific should be set.
Declaration
public bool? CultureSpecific { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<System.Boolean> | If PropertyDefinition should be culture specific |
Remarks
This value is extracted from CultureSpecificAttribute
If the nullable does not have a value it means that the attribute was not set.
Description
Gets or sets the description for the generated HelpText
Declaration
public string Description { get; set; }
Property Value
Type | Description |
---|---|
System.String | The description. |
Remarks
This value is extracted from System.ComponentModel.DataAnnotations.DisplayAttribute.Description
DisplayName
Gets or sets the description for the generated EditCaption
Declaration
public string DisplayName { get; set; }
Property Value
Type | Description |
---|---|
System.String | The display name. |
Remarks
This value is extracted from System.ComponentModel.DataAnnotations.DisplayAttribute.Name
EditorHint
Gets or sets editor hint that will be used when resolving render in EditMode
Declaration
public string EditorHint { get; set; }
Property Value
Type | Description |
---|---|
System.String |
ExistingPropertyDefinition
Declaration
public PropertyDefinition ExistingPropertyDefinition { get; set; }
Property Value
Type | Description |
---|---|
PropertyDefinition |
Name
Gets or set the name of the property on the model.
Declaration
public string Name { get; set; }
Property Value
Type | Description |
---|---|
System.String | The name. |
Order
Gets or sets the sort order for the generated FieldOrder
Declaration
public int? Order { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<System.Int32> | The order. |
Remarks
This value is extracted from System.ComponentModel.DataAnnotations.DisplayAttribute.Order
If the nullable does not have a value it means that the attribute was not set.
Required
Gets or sets the if the generated Required should be set.
Declaration
public bool? Required { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<System.Boolean> | If PropertyDefinition should be culture specific |
Remarks
This value is extracted from System.ComponentModel.DataAnnotations.RequiredAttribute
If the nullable does not have a value it means that the attribute was not set.
Searchable
Gets or sets the if the generated Searchable should be set.
Declaration
public bool? Searchable { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<System.Boolean> | If property instances of PropertyDefinition should be searchable |
Remarks
This value is extracted from SearchableAttribute
If the nullable does not have a value it means that the attribute was not set.
State
Gets the state of the Model corresponding to the matching PropertyDefinition
Declaration
public SynchronizationStatus State { get; }
Property Value
Type | Description |
---|---|
SynchronizationStatus | The state. |
TabName
Gets or sets the name of the TabDefinition that the property will be
Declaration
public string TabName { get; set; }
Property Value
Type | Description |
---|---|
System.String | The name of the tab. |
Remarks
This value is extracted from System.ComponentModel.DataAnnotations.DisplayAttribute.GroupName
TemplateHint
Gets or sets the template hint that will be used when resolving render.
Declaration
public string TemplateHint { get; set; }
Property Value
Type | Description |
---|---|
System.String | The template hint. |
Type
Gets or sets the type of the property on the model.
Declaration
public Type Type { get; set; }
Property Value
Type | Description |
---|---|
System.Type | The type. |
Methods
IsInSynch(PropertyDefinition)
Determines whether the specified property definition is in synch with this instance.
Declaration
public virtual bool IsInSynch(PropertyDefinition propertyDefinition)
Parameters
Type | Name | Description |
---|---|---|
PropertyDefinition | propertyDefinition | The property definition. |
Returns
Type | Description |
---|---|
System.Boolean |
|