ModelAttribute Properties |
The ModelAttribute type exposes the following members.
Name | Description | |
---|---|---|
AutoProperty |
Gets or sets the value of AutoProperty domain property.
If false, generates a backing field and a partial method to hook getting and
setting the property. If true, generates a simple auto property.
| |
CLRType | Converts a C# primitive type to a CLR type. | |
ColumnName |
Gets or sets the value of ColumnName domain property.
The name for the table column backing this property
| |
ColumnType |
Gets or sets the value of ColumnType domain property.
The data type for the table column backing this property
| |
CustomAttributes |
Gets or sets the value of CustomAttributes domain property.
Any custom attributes to be generated for this element. Will be passed through
as entered.
| |
Description |
Gets or sets the value of Description domain property.
Detailed code documentation
| |
DisplayText | ||
FQPrimitiveType | Converts the attribute's CLR type to a C# primitive type. | |
IdentityType |
Gets or sets the value of IdentityType domain property.
If this property is an identity, how the value is generated
| |
Indexed |
Gets or sets the value of Indexed domain property.
Should this attribute create an index in the database?
| |
IndexedUnique |
Gets or sets the value of IndexedUnique domain property.
If indexed, is the index a unique index?
| |
InitialValue |
Gets or sets the value of InitialValue domain property.
Value for attribute when first created
| |
IsConcurrencyToken |
Gets or sets the value of IsConcurrencyToken domain property.
If true, this property serves as the concurrency value for the class
| |
IsIdentity |
Gets or sets the value of IsIdentity domain property.
Does this attribute represent the identity of the object?
| |
MaxLength |
Gets or sets the value of MaxLength domain property.
Maximum length of the string, A positive number will generate a length
constraint, negative number means the database maximum (approx. 2GB), and null
or 0 for no max length entry (migration traditionally will set the database
column to 2000 characters).
| |
MinLength |
Gets or sets the value of MinLength domain property.
Minimum length of the string, 0 for no minimum length
| |
ModelClass |
Gets or sets ModelClass.
| |
Name |
Gets or sets the value of Name domain property.
The name of the property. Must be a valid C# symbol.
| |
ParentModelElement | Gets the parent model element (ModelClass). | |
Partition | (Inherited from ModelElement.) | |
Persistent |
Gets or sets the value of Persistent domain property.
Attribute will be stored in persistent storage
| |
PrimitiveType |
From internal class System.Data.Metadata.Edm.PrimitiveType in System.Data.Entity. Converts the attribute's CLR type to a C# primitive type.
| |
ReadOnly |
Gets or sets the value of ReadOnly domain property.
If true, no setter will be generated. Only valid for transient public
properties.
| |
Required |
Gets or sets the value of Required domain property.
If true, cannot be null (or the default value for the property type, if not
nullable)
| |
SetterVisibility |
Gets or sets the value of SetterVisibility domain property.
Visibility for property setter; getter is public
| |
Store | (Inherited from ModelElement.) | |
StringType |
Gets or sets the value of StringType domain property.
If not empty, will create a standard validation annotation for this attribute.
| |
Summary |
Gets or sets the value of Summary domain property.
Brief code documentation
| |
TableOverride |
Gets or sets the value of TableOverride domain property.
Unused - Alternate table to store this attribute. If empty, the class's table is
used.
| |
Type |
Gets or sets the value of Type domain property.
Type of this attribute
| |
Virtual |
Gets or sets the value of Virtual domain property.
If true, property will be generated with the 'virtual' keyword
|