Class PropertyModel
Represents a model property.
Inheritance
System.Object
Namespace: Umbraco.Cms.Infrastructure.ModelsBuilder.Building
Assembly: Umbraco.Infrastructure.dll
Syntax
public class PropertyModel
Fields
View SourceAlias
Gets the alias of the property.
Declaration
public string Alias
Field Value
Type | Description |
---|---|
System.String |
ClrName
Gets the clr name of the property.
Declaration
public string ClrName
Field Value
Type | Description |
---|---|
System.String |
Remarks
This is just the local name eg "Price".
ClrTypeName
Gets the CLR type name of the property values.
Declaration
public string ClrTypeName
Field Value
Type | Description |
---|---|
System.String |
Description
Gets the description of the property.
Declaration
public string Description
Field Value
Type | Description |
---|---|
System.String |
Errors
Gets the generation errors for the property.
Declaration
public List<string>? Errors
Field Value
Type | Description |
---|---|
System.Nullable<List<System.String>> |
Remarks
This should be null, unless something prevents the property from being generated, and then the value should explain what. This can be used to generate commented out code eg in InMemoryAuto mode.
ModelClrType
Gets the Model Clr type of the property values.
Declaration
public Type ModelClrType
Field Value
Type | Description |
---|---|
Type |
Remarks
As indicated by the PublishedPropertyType
, ie by the IPropertyValueConverter
if any, else object
. May include some ModelType that will need to be mapped.
Name
Gets the name of the property.
Declaration
public string Name
Field Value
Type | Description |
---|---|
System.String |
Methods
View SourceAddError(String)
Adds an error.
Declaration
public void AddError(string error)
Parameters
Type | Name | Description |
---|---|---|
System.String | error |