Bagikan melalui


ConventionPropertyExtensions.SetScale Metode

Definisi

Mengatur skala data yang diizinkan dalam properti ini. Misalnya, jika properti adalah maka Decimal ini adalah jumlah maksimum tempat desimal.

public static int? SetScale (this Microsoft.EntityFrameworkCore.Metadata.IConventionProperty property, int? scale, bool fromDataAnnotation = false);
static member SetScale : Microsoft.EntityFrameworkCore.Metadata.IConventionProperty * Nullable<int> * bool -> Nullable<int>
<Extension()>
Public Function SetScale (property As IConventionProperty, scale As Nullable(Of Integer), Optional fromDataAnnotation As Boolean = false) As Nullable(Of Integer)

Parameter

property
IConventionProperty

Properti .

scale
Nullable<Int32>

Jumlah maksimum tempat desimal yang diperbolehkan di properti ini.

fromDataAnnotation
Boolean

Menunjukkan apakah konfigurasi ditentukan menggunakan anotasi data.

Mengembalikan

Berlaku untuk