IConventionEntityTypeBuilder.CanSetBaseType 方法

定義

傳回值,指出指定的型別是否可以設定為這個實體類型的基底類型。

public bool CanSetBaseType (Microsoft.EntityFrameworkCore.Metadata.IConventionEntityType baseEntityType, bool fromDataAnnotation = false);
public bool CanSetBaseType (Microsoft.EntityFrameworkCore.Metadata.IConventionEntityType? baseEntityType, bool fromDataAnnotation = false);
abstract member CanSetBaseType : Microsoft.EntityFrameworkCore.Metadata.IConventionEntityType * bool -> bool
Public Function CanSetBaseType (baseEntityType As IConventionEntityType, Optional fromDataAnnotation As Boolean = false) As Boolean

參數

baseEntityType
IConventionEntityType

基底實體類型,或 null 表示沒有基底類型。

fromDataAnnotation
Boolean

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

傳回

true 如果指定的型別可以設定為這個實體類型的基底類型,則為 。

適用於