Share via


ConventionPropertyExtensions.SetProviderClrType Metodo

Definizione

Imposta il tipo in cui verrà convertito il valore della proprietà prima di essere inviato al provider di database.

public static void SetProviderClrType (this Microsoft.EntityFrameworkCore.Metadata.IConventionProperty property, Type providerClrType, bool fromDataAnnotation = false);
public static Type SetProviderClrType (this Microsoft.EntityFrameworkCore.Metadata.IConventionProperty property, Type providerClrType, bool fromDataAnnotation = false);
static member SetProviderClrType : Microsoft.EntityFrameworkCore.Metadata.IConventionProperty * Type * bool -> unit
static member SetProviderClrType : Microsoft.EntityFrameworkCore.Metadata.IConventionProperty * Type * bool -> Type
<Extension()>
Public Sub SetProviderClrType (property As IConventionProperty, providerClrType As Type, Optional fromDataAnnotation As Boolean = false)
<Extension()>
Public Function SetProviderClrType (property As IConventionProperty, providerClrType As Type, Optional fromDataAnnotation As Boolean = false) As Type

Parametri

property
IConventionProperty

Proprietà.

providerClrType
Type

Tipo da usare o null da rimuovere qualsiasi tipo di set precedentemente impostato.

fromDataAnnotation
Boolean

Indica se la configurazione è stata specificata usando un'annotazione dati.

Restituisce

Il valore configurato.

Si applica a