RelationalModelBuilderExtensions.CanSetMaxIdentifierLength 方法

定義

傳回值,指出是否可以設定存放區識別碼允許的最大長度。

public static bool CanSetMaxIdentifierLength (this Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionModelBuilder modelBuilder, int? length, bool fromDataAnnotation = false);
static member CanSetMaxIdentifierLength : Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionModelBuilder * Nullable<int> * bool -> bool
<Extension()>
Public Function CanSetMaxIdentifierLength (modelBuilder As IConventionModelBuilder, length As Nullable(Of Integer), Optional fromDataAnnotation As Boolean = false) As Boolean

參數

modelBuilder
IConventionModelBuilder

模型產生器。

length
Nullable<Int32>

要設定的值。

fromDataAnnotation
Boolean

指出是否使用資料批註來指定組態。

傳回

true 如果可以設定存放區識別碼允許的最大長度,則為 。

備註

如需詳細資訊和範例,請參閱 模型化實體類型和關聯 性。

適用於