ConventionEntityTypeExtensions.AddProperty Yöntem

Tanım

Aşırı Yüklemeler

AddProperty(IConventionEntityType, MemberInfo, Boolean)

Bu varlık türüne bir özellik ekler.

AddProperty(IConventionEntityType, String, Boolean)

Bu varlık türüne bir özellik ekler.

AddProperty(IConventionEntityType, String, Type, Boolean, Boolean)

Bu varlık türüne bir özellik ekler.

AddProperty(IConventionEntityType, MemberInfo, Boolean)

Bu varlık türüne bir özellik ekler.

public static Microsoft.EntityFrameworkCore.Metadata.IConventionProperty AddProperty (this Microsoft.EntityFrameworkCore.Metadata.IConventionEntityType entityType, System.Reflection.MemberInfo memberInfo, bool fromDataAnnotation = false);
static member AddProperty : Microsoft.EntityFrameworkCore.Metadata.IConventionEntityType * System.Reflection.MemberInfo * bool -> Microsoft.EntityFrameworkCore.Metadata.IConventionProperty
<Extension()>
Public Function AddProperty (entityType As IConventionEntityType, memberInfo As MemberInfo, Optional fromDataAnnotation As Boolean = false) As IConventionProperty

Parametreler

entityType
IConventionEntityType

Varlık türü.

memberInfo
MemberInfo

Varlık sınıfında karşılık gelen üye.

fromDataAnnotation
Boolean

Yapılandırmanın veri ek açıklaması kullanılarak belirtilmemiş olup olmadığını gösterir.

Döndürülenler

IConventionProperty

Yeni oluşturulan özellik.

Şunlara uygulanır

AddProperty(IConventionEntityType, String, Boolean)

Bu varlık türüne bir özellik ekler.

public static Microsoft.EntityFrameworkCore.Metadata.IConventionProperty AddProperty (this Microsoft.EntityFrameworkCore.Metadata.IConventionEntityType entityType, string name, bool fromDataAnnotation = false);
static member AddProperty : Microsoft.EntityFrameworkCore.Metadata.IConventionEntityType * string * bool -> Microsoft.EntityFrameworkCore.Metadata.IConventionProperty
<Extension()>
Public Function AddProperty (entityType As IConventionEntityType, name As String, Optional fromDataAnnotation As Boolean = false) As IConventionProperty

Parametreler

entityType
IConventionEntityType

Varlık türü.

name
String

Eklemek istediğiniz özelliğin adı.

fromDataAnnotation
Boolean

Yapılandırmanın veri ek açıklaması kullanılarak belirtilmemiş olup olmadığını gösterir.

Döndürülenler

IConventionProperty

Yeni oluşturulan özellik.

Şunlara uygulanır

AddProperty(IConventionEntityType, String, Type, Boolean, Boolean)

Bu varlık türüne bir özellik ekler.

public static Microsoft.EntityFrameworkCore.Metadata.IConventionProperty AddProperty (this Microsoft.EntityFrameworkCore.Metadata.IConventionEntityType entityType, string name, Type propertyType, bool setTypeConfigurationSource = true, bool fromDataAnnotation = false);
static member AddProperty : Microsoft.EntityFrameworkCore.Metadata.IConventionEntityType * string * Type * bool * bool -> Microsoft.EntityFrameworkCore.Metadata.IConventionProperty
<Extension()>
Public Function AddProperty (entityType As IConventionEntityType, name As String, propertyType As Type, Optional setTypeConfigurationSource As Boolean = true, Optional fromDataAnnotation As Boolean = false) As IConventionProperty

Parametreler

entityType
IConventionEntityType

Varlık türü.

name
String

Eklemek istediğiniz özelliğin adı.

propertyType
Type

Özelliğin tutacak olduğu değer türü.

setTypeConfigurationSource
Boolean

Tür yapılandırma kaynağının ayar olup olmadığını gösterir.

fromDataAnnotation
Boolean

Yapılandırmanın veri ek açıklaması kullanılarak belirtilmemiş olup olmadığını gösterir.

Döndürülenler

IConventionProperty

Yeni oluşturulan özellik.

Şunlara uygulanır