語言

IConventionSequence 介面

定義

在模型中以可在建構模型時進行變異的形式,表示資料庫序列。

public interface IConventionSequence : Microsoft.EntityFrameworkCore.Metadata.IConventionAnnotatable, Microsoft.EntityFrameworkCore.Metadata.IReadOnlySequence
public interface IConventionSequence : Microsoft.EntityFrameworkCore.Metadata.ISequence
public interface IConventionSequence : Microsoft.EntityFrameworkCore.Metadata.IConventionAnnotatable, Microsoft.EntityFrameworkCore.Metadata.ISequence
type IConventionSequence = interface
    interface IReadOnlySequence
    interface IReadOnlyAnnotatable
    interface IConventionAnnotatable
type IConventionSequence = interface
    interface ISequence
type IConventionSequence = interface
    interface ISequence
    interface IAnnotatable
    interface IConventionAnnotatable
Public Interface IConventionSequence
Implements IConventionAnnotatable, IReadOnlySequence
Public Interface IConventionSequence
Implements ISequence
Public Interface IConventionSequence
Implements IConventionAnnotatable, ISequence
實作

備註

更多資訊與範例請參見 資料庫序列 。

屬性

名稱 Description
Builder

取得可用來配置此序列的建構器。

ClrType
已淘汰.

取得 Type 序列回傳的值。

(繼承來源 ISequence)
IncrementBy

取得每個新值時的增量。

(繼承來源 ISequence)
IsCyclic

取得值,表示當達到最大值時,序列是否會從頭開始。

(繼承來源 ISequence)
IsInModel

表示該物件是否在模型中,也就是尚未從模型中移除。

(繼承來源 IConventionAnnotatable)
Item[String]

取得帶有名稱的值註解,若不存在則回 null 傳。

(繼承來源 IAnnotatable)
MaxValue

取得序列所支持的最大值,或 null 若未設定序列。

(繼承來源 ISequence)
MinValue

取得序列所支持的最小值,或 null 若未設定序列。

(繼承來源 ISequence)
Model

得到 IConventionModel 定義此序列的 。

ModelSchema

取得序列的模型結構。 這是在 中 HasSequence(ModelBuilder, String, String) 指定的,也是要與 FindSequence(IConventionModel, String, String)一起使用的。

(繼承來源 IReadOnlySequence)
Name

取得資料庫中序列名稱。

(繼承來源 ISequence)
Schema

取得包含序列的資料庫結構。

(繼承來源 ISequence)
StartValue

取得序列起始的值。

(繼承來源 ISequence)
Type

取得 Type 序列回傳的值。

(繼承來源 ISequence)

方法

名稱 Description
AddAnnotation(String, Object, Boolean)

為此物件新增註解。 如果已有指定名稱的註解存在,則會拋出。

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

為物件添加註解。

(繼承來源 IConventionAnnotatable)
AddRuntimeAnnotation(String, Object)

為此物件新增執行時註解。 如果已有指定名稱的註解存在,則會拋出。

(繼承來源 IAnnotatable)
AnnotationsToDebugString(Int32)

取得物件上所有宣告註解的除錯字串。

(繼承來源 IReadOnlyAnnotatable)
FindAnnotation(String)

取得帶有名字的註解,若不存在則回 null 傳。

(繼承來源 IAnnotatable)
FindRuntimeAnnotation(String)

取得帶有名稱的執行時註解,若不存在則回 null 傳。

(繼承來源 IAnnotatable)
FindRuntimeAnnotationValue(String)

取得執行時註解的值,若名稱不存在則回 null 傳。

(繼承來源 IAnnotatable)
GetAnnotation(String)

取得帶有名稱的註解,若不存在則拋出。

(繼承來源 IConventionAnnotatable)
GetAnnotations()

取得目前物件的所有註解。

(繼承來源 IAnnotatable)
GetClrTypeConfigurationSource()
已淘汰.

取得 的 ClrType配置來源。

GetConfigurationSource()

取得這個 IConventionSequence設定的來源。

GetIncrementByConfigurationSource()

取得 的 IncrementBy配置來源。

GetIsCyclicConfigurationSource()

取得 的 IsCyclic配置來源。

GetMaxValueConfigurationSource()

取得 的 MaxValue配置來源。

GetMinValueConfigurationSource()

回傳 的 MinValue配置來源。

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

取得帶有名稱的執行時註解值,若不存在則加入該註解。

(繼承來源 IAnnotatable)
GetRuntimeAnnotations()

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

(繼承來源 IAnnotatable)
GetStartValueConfigurationSource()

回傳 的 StartValue配置來源。

GetTypeConfigurationSource()

取得 的 Type配置來源。

RemoveAnnotation(String)

移除這個物件中帶有名字的註解。

(繼承來源 IConventionAnnotatable)
RemoveRuntimeAnnotation(String)

移除該物件中給定的執行時註解。

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

設定以名字儲存的註解。 若已有指定名稱的註解存在,則會覆寫現有註解。

(繼承來源 IConventionAnnotatable)
SetClrType(Type, Boolean)
已淘汰.

設定 Type 序列回傳的值。

SetIncrementBy(Nullable<Int32>, Boolean)

設定每個新值的增量。

SetIsCyclic(Nullable<Boolean>, Boolean)

設定當達到最大值時,序列是否會從頭開始。

SetMaxValue(Nullable<Int64>, Boolean)

設定序列所支持的最大值。

SetMinValue(Nullable<Int64>, Boolean)

設定序列所支撐的最小值。

SetOrRemoveAnnotation(String, Object, Boolean)

設定以名字儲存的註解。 若已有指定名稱的註解存在,則會覆寫現有註解。 若 null 提供 則移除現有註解。

(繼承來源 IConventionAnnotatable)
SetRuntimeAnnotation(String, Object)

設定在指定鍵值下儲存的執行時註解。 若已有指定名稱的註解存在,則會覆寫現有註解。

(繼承來源 IAnnotatable)
SetStartValue(Nullable<Int64>, Boolean)

設定序列起始的值。

SetType(Type, Boolean)

設定 Type 序列回傳的值。

ToDebugString(MetadataDebugStringOptions, Int32)

建立給定元資料的可讀表示法。

警告:請勿依賴回傳字串的格式。 它僅設計用於除錯,且可能在不同版本間任意變動。

(繼承來源 IReadOnlySequence)

擴充方法

名稱 Description
AddAnnotations(IConventionAnnotatable, IEnumerable<IConventionAnnotation>, Boolean)

為物件添加註解。

AnnotationsToDebugString(IAnnotatable, Int32)

取得物件上所有宣告註解的除錯字串。

GetAnnotation(IAnnotatable, String)

取得帶有名稱的註解,若不存在則拋出。

GetAnnotation(IConventionAnnotatable, String)

取得帶有名稱的註解,若不存在則拋出。

SetOrRemoveAnnotation(IConventionAnnotatable, String, Object, Boolean)

設定以名字儲存的註解。 若已有指定名稱的註解存在,則會覆寫現有註解。 若 null 提供 則移除現有註解。

ToDebugString(ISequence, MetadataDebugStringOptions, Int32)

建立給定元資料的可讀表示法。

警告:請勿依賴回傳字串的格式。 它僅設計用於除錯,且可能在不同版本間任意變動。

適用於