IConventionTypeBase 介面

定義

表示 中的 IConventionModel 型別。

public interface IConventionTypeBase : Microsoft.EntityFrameworkCore.Metadata.IConventionAnnotatable, Microsoft.EntityFrameworkCore.Metadata.ITypeBase
public interface IConventionTypeBase : Microsoft.EntityFrameworkCore.Metadata.IConventionAnnotatable, Microsoft.EntityFrameworkCore.Metadata.IReadOnlyTypeBase
type IConventionTypeBase = interface
    interface ITypeBase
    interface IAnnotatable
    interface IConventionAnnotatable
type IConventionTypeBase = interface
    interface IReadOnlyTypeBase
    interface IReadOnlyAnnotatable
    interface IConventionAnnotatable
Public Interface IConventionTypeBase
Implements IConventionAnnotatable, ITypeBase
Public Interface IConventionTypeBase
Implements IConventionAnnotatable, IReadOnlyTypeBase
衍生
實作

備註

此介面會在模型建立期間使用,並允許修改中繼資料。 建置模型之後, IReadOnlyTypeBase 表示相同中繼資料的唯讀檢視。

如需詳細資訊和範例,請參閱 模型建置慣例

屬性

Builder

取得可用來設定此類型的產生器。

ClrType

取得用來表示此型別實例的 CLR 類別。 null如果類型沒有對應的 CLR 類別, (稱為陰影類型) ,則傳回 。

(繼承來源 IReadOnlyTypeBase)
ConstructorBinding

InstantiationBinding取得慣用建構函式的 。

(繼承來源 ITypeBase)
ContainingEntityType

取得這個實體類型,或宣告複雜屬性鏈結所在的實體類型。

HasSharedClrType

取得值,指出這個結構型別是否對應至 Type 其他結構化類型的 對應。

(繼承來源 IReadOnlyTypeBase)
IsInModel

指出此物件是否在模型中,亦即尚未從其中移除。

(繼承來源 IConventionAnnotatable)
IsPropertyBag

取得值,指出這個結構類型是否具有索引子,這個索引子是否能夠包含任意屬性,以及可用來判斷指定索引子屬性是否包含值的方法。

(繼承來源 IReadOnlyTypeBase)
Item[String]

取得具有指定名稱的注釋值,如果不存在,則傳 null 回 。

(繼承來源 IReadOnlyAnnotatable)
Model

取得這個類型所屬的模型。

Name

取得這個型別的名稱。

(繼承來源 IReadOnlyTypeBase)

方法

AddAnnotation(String, Object, Boolean)

將批註加入至這個物件。 如果具有指定名稱的注釋已經存在,則會擲回 。

(繼承來源 IConventionAnnotatable)
AddAnnotations(IEnumerable<IConventionAnnotation>, Boolean)

將批註加入物件。

(繼承來源 IConventionAnnotatable)
AddComplexIndexerProperty(String, Type, Type, String, Boolean, Boolean)

將 和 索引子所支援的屬性加入至此類型。

AddComplexProperty(MemberInfo, String, Boolean, Boolean)

將屬性加入至此類型。

AddComplexProperty(String, Boolean, Boolean)

將屬性加入至此類型。

AddComplexProperty(String, Type, MemberInfo, Type, String, Boolean, Boolean)

將屬性加入至此類型。

AddComplexProperty(String, Type, Type, String, Boolean, Boolean)

將屬性加入至此類型。

AddIgnored(String, Boolean)

將指定的成員名稱標示為忽略,防止慣例將相符的屬性或導覽新增至類型。

AddIndexerProperty(String, Type, Boolean, Boolean)

將 和 索引子所支援的屬性加入至這個實體類型。

AddProperty(MemberInfo, Boolean)

將屬性加入至這個實體類型。

AddProperty(String, Boolean)

將屬性加入至這個實體類型。

AddProperty(String, Type, Boolean, Boolean)

將屬性加入至這個實體類型。

AddProperty(String, Type, MemberInfo, Boolean, Boolean)

將屬性加入至這個實體類型。

AddRuntimeAnnotation(String, Object)

將執行時間批註加入至這個物件。 如果具有指定名稱的注釋已經存在,則會擲回 。

(繼承來源 IAnnotatable)
AnnotationsToDebugString(Int32)

取得 物件上宣告之所有批註的偵錯字串。

(繼承來源 IReadOnlyAnnotatable)
DisplayName()

取得這個結構化類型的易記顯示名稱。

(繼承來源 IReadOnlyTypeBase)
DisplayName(Boolean)

取得指定 IReadOnlyTypeBase 之 的易記顯示名稱。

(繼承來源 IReadOnlyTypeBase)
FindAnnotation(String)

取得具有指定名稱的注釋,如果不存在,則傳 null 回 。

(繼承來源 IReadOnlyAnnotatable)
FindComplexProperty(MemberInfo)

取得具有指定成員資訊的複雜屬性。 如果找不到任何屬性,則傳 null 回 。

FindComplexProperty(String)

取得具有指定名稱的複雜屬性。 如果未定義具有指定名稱的屬性,則傳 null 回 。

FindDeclaredComplexProperty(String)

尋找在具有指定名稱之型別上宣告的屬性。 不會傳回基底類型上定義的屬性。

FindDeclaredProperty(String)

尋找在具有指定名稱之型別上宣告的屬性。 不會傳回基底類型上定義的屬性。

FindIgnoredConfigurationSource(String)

指出是否忽略指定的成員名稱。

FindIndexerPropertyInfo()

PropertyInfo如果關聯 CLR 類型存在,則傳回索引子的 。

(繼承來源 IReadOnlyTypeBase)
FindMember(String)

取得具有指定名稱的成員。 如果未定義具有指定名稱的成員,則傳 null 回 。

FindMembersInHierarchy(String)

取得這個型別、基底類型或衍生型別上具有指定名稱的成員。

FindProperties(IReadOnlyList<String>)

在指定的實體類型上尋找相符的屬性。 如果找不到任何屬性,則傳 null 回 。

FindProperty(MemberInfo)

取得指定實體類型上的屬性。 如果找不到任何屬性,則傳 null 回 。

FindProperty(String)

取得具有指定名稱的屬性。 如果未定義具有指定名稱的屬性,則傳 null 回 。

FindRuntimeAnnotation(String)

取得具有指定名稱的執行時間批註,如果不存在,則傳 null 回 。

(繼承來源 IAnnotatable)
FindRuntimeAnnotationValue(String)

取得具有指定名稱的執行時間批註值,如果不存在,則傳 null 回 。

(繼承來源 IAnnotatable)
GetAnnotation(String)

取得具有指定名稱的注釋,如果不存在,則會擲回。

(繼承來源 IReadOnlyAnnotatable)
GetAnnotations()

取得目前 物件上的所有批註。

(繼承來源 IReadOnlyAnnotatable)
GetChangeTrackingStrategy()

取得用於此類型的變更追蹤策略。 此策略指出內容如何偵測類型實例的屬性變更。

(繼承來源 IReadOnlyTypeBase)
GetChangeTrackingStrategyConfigurationSource()

傳回 的 GetChangeTrackingStrategy() 組態來源。

GetComplexProperties()

取得在這個類型上定義的複雜屬性。

GetDeclaredComplexProperties()

取得在這個類型上宣告的複雜屬性。

GetDeclaredMembers()

取得在這個類型上宣告的成員。

GetDeclaredProperties()

取得在此類型上宣告的所有純量屬性。

GetDerivedComplexProperties()

取得衍生自這個型別之型別上宣告的複雜屬性。

GetDerivedProperties()

取得衍生自此型別之型別上宣告的所有純量屬性。

GetFlattenedComplexProperties()

傳回實作 IComplexProperty 的所有屬性,包括複雜型別上的屬性。

(繼承來源 ITypeBase)
GetFlattenedDeclaredProperties()

傳回所有實 IProperty 作 的宣告屬性,包括複雜型別上的屬性。

(繼承來源 ITypeBase)
GetFlattenedProperties()

傳回實作 IProperty 的所有屬性,包括複雜型別上的屬性。

(繼承來源 ITypeBase)
GetIgnoredMembers()

取得所有忽略的成員。

GetMembers()

取得在這個型別和基底型別上定義的成員。

GetNavigationAccessMode()

PropertyAccessMode取得用於這個型別導覽的 。

(繼承來源 IReadOnlyTypeBase)
GetNavigationAccessModeConfigurationSource()

傳回 的 GetNavigationAccessMode() 組態來源。

GetOrAddRuntimeAnnotationValue<TValue,TArg>(String, Func<TArg,TValue>, TArg)

取得具有指定名稱的執行時間注釋值,如果不存在,請加以新增。

(繼承來源 IAnnotatable)
GetProperties()

取得在此類型上定義的所有純量屬性。

GetProperty(String)

取得具有指定名稱的屬性。

GetPropertyAccessMode()

PropertyAccessMode取得用於這個類型之屬性和導覽的 。

(繼承來源 IReadOnlyTypeBase)
GetPropertyAccessModeConfigurationSource()

傳回 的 GetPropertyAccessMode() 組態來源。

GetRuntimeAnnotations()

取得目前 物件上的所有執行時間批註。

(繼承來源 IAnnotatable)
GetSnapshottableMembers()

傳回變更追蹤時可能需要快照集值的所有成員。

(繼承來源 ITypeBase)
IsAbstract()

取得值,指出這個結構類型是否代表抽象型別。

(繼承來源 IReadOnlyTypeBase)
IsAssignableFrom(IReadOnlyTypeBase)

判斷此類型是否衍生自 (,或與指定類型) 相同。

(繼承來源 IReadOnlyTypeBase)
IsIgnored(String)

指出是否忽略指定的成員名稱。

IsStrictlyDerivedFrom(IReadOnlyTypeBase)

判斷此類型是否衍生自 (,但與指定類型) 不同。

(繼承來源 IReadOnlyTypeBase)
RemoveAnnotation(String)

從這個 物件中移除具有指定名稱的批註。

(繼承來源 IConventionAnnotatable)
RemoveComplexProperty(IConventionComplexProperty)

從這個類型移除 屬性。

RemoveComplexProperty(String)

從這個類型移除 屬性。

RemoveIgnored(String)

移除忽略的成員名稱。

RemoveProperty(IReadOnlyProperty)

從這個類型移除 屬性。

RemoveProperty(String)

從這個類型移除 屬性。

RemoveRuntimeAnnotation(String)

從這個 物件中移除指定的執行時間批註。

(繼承來源 IAnnotatable)
SetAnnotation(String, Object, Boolean)

設定儲存在指定名稱下的批註。 如果具有指定名稱的注釋已經存在,則覆寫現有的注釋。

(繼承來源 IConventionAnnotatable)
SetChangeTrackingStrategy(Nullable<ChangeTrackingStrategy>, Boolean)

設定要用於此類型的變更追蹤策略。 此策略指出內容如何偵測類型實例的屬性變更。

SetNavigationAccessMode(Nullable<PropertyAccessMode>, Boolean)

PropertyAccessMode設定要用於此實體型別導覽的 。

SetOrRemoveAnnotation(String, Object, Boolean)

設定儲存在指定名稱下的批註。 如果具有指定名稱的注釋已經存在,則覆寫現有的注釋。 如果 null 已提供,則移除現有的批註。

(繼承來源 IConventionAnnotatable)
SetPropertyAccessMode(Nullable<PropertyAccessMode>, Boolean)

PropertyAccessMode設定要用於此類型屬性的 。

SetRuntimeAnnotation(String, Object)

設定儲存在指定索引鍵下的執行時間批註。 如果具有指定名稱的注釋已經存在,則覆寫現有的注釋。

(繼承來源 IAnnotatable)
ShortName()

取得可用於其他識別碼之 的 IReadOnlyTypeBase 簡短名稱。

(繼承來源 IReadOnlyTypeBase)

擴充方法

AddAnnotations(IConventionAnnotatable, IEnumerable<IConventionAnnotation>, Boolean)

將批註加入物件。

GetAnnotation(IConventionAnnotatable, String)

取得具有指定名稱的注釋,如果不存在,則會擲回。

SetOrRemoveAnnotation(IConventionAnnotatable, String, Object, Boolean)

設定儲存在指定名稱下的批註。 如果具有指定名稱的注釋已經存在,則覆寫現有的注釋。 如果 null 已提供,則移除現有的批註。

GetNavigationAccessModeConfigurationSource(IConventionTypeBase)

傳回 的 GetNavigationAccessMode(ITypeBase) 組態來源。

GetPropertyAccessModeConfigurationSource(IConventionTypeBase)

傳回 的 GetPropertyAccessMode(ITypeBase) 組態來源。

IsIgnored(IConventionTypeBase, String)

指出是否忽略指定的成員名稱。

SetNavigationAccessMode(IConventionTypeBase, Nullable<PropertyAccessMode>, Boolean)

PropertyAccessMode設定要用於巡覽這個實體型別的 。

請注意,個別導覽可以覆寫此存取模式。 此處設定的值將用於未指定任何覆寫的任何導覽。

SetPropertyAccessMode(IConventionTypeBase, Nullable<PropertyAccessMode>, Boolean)

PropertyAccessMode設定要用於這個型別之屬性的 。

請注意,個別屬性和導覽可以覆寫此存取模式。 此處設定的值將用於未指定覆寫的任何屬性或導覽。

DisplayName(ITypeBase)

取得指定 ITypeBase 之 的易記顯示名稱。

FullName(ITypeBase)
已過時。.

取得指定 IReadOnlyTypeBase 的唯一名稱。

IsAbstract(ITypeBase)

檢查此實體類型是否代表抽象類別型。

ShortName(ITypeBase)

取得可用於 ITypeBase 其他識別碼之 的簡短名稱。

AnnotationsToDebugString(IAnnotatable, Int32)

取得 物件上宣告之所有批註的偵錯字串。

GetAnnotation(IAnnotatable, String)

取得具有指定名稱的注釋,如果不存在,則會擲回。

FindMappingFragment(IReadOnlyTypeBase, StoreObjectIdentifier)

傳回特定類似資料表的存放區物件的型別對應。

這個方法通常由資料庫提供者使用, (和其他延伸模組) 。 它通常不會用於應用程式程式碼中。

GetContainerColumnName(IReadOnlyTypeBase)

取得類型所對應的容器資料行名稱。

GetDeleteStoredProcedure(IReadOnlyTypeBase)

傳回型別要對應以進行刪除的預存程式, null 如果未對應至預存程式,則傳回該預存程式。

GetFunctionName(IReadOnlyTypeBase)

傳回型別所 null 對應之函式的名稱,如果不是對應至函式,則傳回該函式的名稱。

GetInsertStoredProcedure(IReadOnlyTypeBase)

傳回類型要對應以進行插入的預存程式, null 如果未對應至預存程式,則傳回該預存程式。

GetJsonPropertyName(IReadOnlyTypeBase)

取得用於對應至 JSON 資料行之指定實體的 JSON 屬性名稱值。

GetMappingFragments(IReadOnlyTypeBase)

傳回所有已設定的類型對應片段。

這個方法通常由資料庫提供者使用, (和其他延伸模組) 。 它通常不會用於應用程式程式碼中。

GetMappingFragments(IReadOnlyTypeBase, StoreObjectType)

傳回指定型別的所有已設定型別對應片段。

這個方法通常由資料庫提供者使用, (和其他延伸模組) 。 它通常不會用於應用程式程式碼中。

GetMappingStrategy(IReadOnlyTypeBase)

取得衍生型別的對應策略。

GetSchema(IReadOnlyTypeBase)

傳回包含對應資料表的資料庫架構。

GetSqlQuery(IReadOnlyTypeBase)

傳回用來提供型 null 別資料的 SQL 字串,如果未對應至 SQL 字串,則傳回 。

GetTableName(IReadOnlyTypeBase)

傳回類型所對應 null 或未對應至資料表的資料表名稱。

GetUpdateStoredProcedure(IReadOnlyTypeBase)

傳回類型要對應至更新的預存程式,如果 null 未對應至預存程式,則傳回該預存程式。

GetViewName(IReadOnlyTypeBase)

傳回類型 null 所對應或未對應至檢視的檢視名稱。

GetViewSchema(IReadOnlyTypeBase)

傳回包含對應檢視的資料庫架構。

IsMappedToJson(IReadOnlyTypeBase)

取得值,指出指定的實體是否對應至 JSON 資料行。

GetNavigationAccessMode(ITypeBase)

PropertyAccessMode取得用於這個型別導覽的 。

請注意,個別導覽可以覆寫此存取模式。 此處傳回的值將用於未指定覆寫的任何流覽。

GetPropertyAccessMode(ITypeBase)

PropertyAccessMode取得用於這個類型之屬性和導覽的 。

請注意,個別屬性和導覽可以覆寫此存取模式。 此處傳回的值將用於未指定覆寫的任何屬性或導覽。

適用於