PropertyExtensions PropertyExtensions Class

Definition

Extension methods for IProperty.

public static class PropertyExtensions
Public Module PropertyExtensions
Inheritance
System.ObjectSystem.Object
PropertyExtensionsPropertyExtensions

Methods

Equals(Object) Equals(Object)

Inherited from System.Object

Equals(Object, Object) Equals(Object, Object)

Inherited from System.Object

GetContainingForeignKeys(IProperty) GetContainingForeignKeys(IProperty)

Gets all foreign keys that use this property (including composite foreign keys in which this property is included).

public static IEnumerable<IForeignKey> GetContainingForeignKeys(this IProperty property)
<ExtensionAttribute>
Public Shared Function GetContainingForeignKeys(property As IProperty) As IEnumerable(Of IForeignKey)
Parameters
property
IProperty IProperty

The property to get foreign keys for.

Returns
System.Collections.Generic.IEnumerable<IForeignKey> System.Collections.Generic.IEnumerable(Of IForeignKey)

The foreign keys that use this property.

GetContainingIndexes(IProperty) GetContainingIndexes(IProperty)

Gets all indexes that use this property (including composite indexes in which this property is included).

public static IEnumerable<IIndex> GetContainingIndexes(this IProperty property)
<ExtensionAttribute>
Public Shared Function GetContainingIndexes(property As IProperty) As IEnumerable(Of IIndex)
Parameters
property
IProperty IProperty

The property to get indexes for.

Returns
System.Collections.Generic.IEnumerable<IIndex> System.Collections.Generic.IEnumerable(Of IIndex)

The indexes that use this property.

GetContainingKeys(IProperty) GetContainingKeys(IProperty)

Gets all primary or alternate keys that use this property (including composite keys in which this property is included).

public static IEnumerable<IKey> GetContainingKeys(this IProperty property)
<ExtensionAttribute>
Public Shared Function GetContainingKeys(property As IProperty) As IEnumerable(Of IKey)
Parameters
property
IProperty IProperty

The property to get primary and alternate keys for.

Returns
System.Collections.Generic.IEnumerable<IKey> System.Collections.Generic.IEnumerable(Of IKey)

The primary and alternate keys that use this property.

GetContainingPrimaryKey(IProperty) GetContainingPrimaryKey(IProperty)

Gets the primary key that uses this property (including a composite primary key in which this property is included).

public static IKey GetContainingPrimaryKey(this IProperty property)
<ExtensionAttribute>
Public Shared Function GetContainingPrimaryKey(property As IProperty) As IKey
Parameters
property
IProperty IProperty

The property to get primary key for.

Returns

The primary that use this property, or null if it is not part of the primary key.

GetHashCode() GetHashCode()

Inherited from System.Object

GetMaxLength(IProperty) GetMaxLength(IProperty)

Gets the maximum length of data that is allowed in this property. For example, if the property is a System.String ' then this is the maximum number of characters.

public static int ? GetMaxLength(this IProperty property)
<ExtensionAttribute>
Public Shared Function GetMaxLength(property As IProperty) As Integer?
Parameters
property
IProperty IProperty

The property to get the maximum length of.

Returns
System.Nullable<System.Int32> System.Nullable(Of System.Int32)

The maximum length, or null if none if defined.

GetType() GetType()

Inherited from System.Object

GetValueGeneratorFactory(IProperty) GetValueGeneratorFactory(IProperty)

Gets the factory that has been set to generate values for this property, if any.

public static Func<IProperty, IEntityType, ValueGenerator> GetValueGeneratorFactory(this IProperty property)
<ExtensionAttribute>
Public Shared Function GetValueGeneratorFactory(property As IProperty) As Func(Of IProperty, IEntityType, ValueGenerator)
Parameters
property
IProperty IProperty

The property to get the value generator factory for.

Returns

The factory, or null if no factory has been set.

IsForeignKey(IProperty) IsForeignKey(IProperty)

Gets a value indicating whether this property is used as a foreign key (or part of a composite foreign key).

public static bool IsForeignKey(this IProperty property)
<ExtensionAttribute>
Public Shared Function IsForeignKey(property As IProperty) As Boolean
Parameters
property
IProperty IProperty

The property to check.

Returns
System.Boolean System.Boolean

True if the property is used as a foreign key, otherwise false.

IsIndex(IProperty) IsIndex(IProperty)

Gets a value indicating whether this property is used as an index (or part of a composite index).

public static bool IsIndex(this IProperty property)
<ExtensionAttribute>
Public Shared Function IsIndex(property As IProperty) As Boolean
Parameters
property
IProperty IProperty

The property to check.

Returns
System.Boolean System.Boolean

True if the property is used as an index, otherwise false.

IsKey(IProperty) IsKey(IProperty)

Gets a value indicating whether this property is used as part of a primary or alternate key (or part of a composite primary or alternate key).

public static bool IsKey(this IProperty property)
<ExtensionAttribute>
Public Shared Function IsKey(property As IProperty) As Boolean
Parameters
property
IProperty IProperty

The property to check.

Returns
System.Boolean System.Boolean

True if the property is part of a key, otherwise false.

IsPrimaryKey(IProperty) IsPrimaryKey(IProperty)

Gets a value indicating whether this property is used as the primary key (or part of a composite primary key).

public static bool IsPrimaryKey(this IProperty property)
<ExtensionAttribute>
Public Shared Function IsPrimaryKey(property As IProperty) As Boolean
Parameters
property
IProperty IProperty

The property to check.

Returns
System.Boolean System.Boolean

True if the property is used as the primary key, otherwise false.

IsUnicode(IProperty) IsUnicode(IProperty)

Gets a value indicating whether or not the property can persist unicode characters.

public static bool ? IsUnicode(this IProperty property)
<ExtensionAttribute>
Public Shared Function IsUnicode(property As IProperty) As Boolean?
Parameters
property
IProperty IProperty

The property to get the unicode setting for.

Returns
System.Nullable<System.Boolean> System.Nullable(Of System.Boolean)

The unicode setting, or null if none if defined.

MemberwiseClone() MemberwiseClone()

Inherited from System.Object

ReferenceEquals(Object, Object) ReferenceEquals(Object, Object)

Inherited from System.Object

ToString() ToString()

Inherited from System.Object