Table of Contents

Class RuntimeSequence

Namespace
Microsoft.EntityFrameworkCore.Metadata
Assembly
Microsoft.EntityFrameworkCore.Relational.dll

Represents a database sequence in the model.

public class RuntimeSequence : AnnotatableBase, ISequence, IReadOnlySequence, IReadOnlyAnnotatable, IAnnotatable
Inheritance
RuntimeSequence
Implements
IReadOnlyAnnotatable
IAnnotatable

Remarks

See Database sequences for more information and examples.

Constructors

RuntimeSequence(string, RuntimeModel, Type, string?, long, int, bool, long?, long?, bool)

Initializes a new instance of the RuntimeSequence class.

public RuntimeSequence(string name, RuntimeModel model, Type type, string? schema = null, long startValue = 1, int incrementBy = 1, bool cyclic = false, long? minValue = null, long? maxValue = null, bool modelSchemaIsNull = false)

Parameters

name string

The sequence name.

model RuntimeModel

The model.

type Type

The type of values generated.

schema string

The schema.

startValue long

The initial value.

incrementBy int

The value increment.

cyclic bool

Whether the sequence is cyclic.

minValue long?

The minimum value.

maxValue long?

The maximum value.

modelSchemaIsNull bool

A value indicating whether ModelSchema is null.

Properties

DebugView

This is an internal API that supports the Entity Framework Core infrastructure and not subject to the same compatibility standards as public APIs. It may be changed or removed without notice in any release. You should only use it directly in your code with extreme caution and knowing that doing so can result in application failures when updating to a new Entity Framework Core release.

public virtual DebugView DebugView { get; }

Property Value

DebugView

Model

Gets the model in which this sequence is defined.

public virtual RuntimeModel Model { get; }

Property Value

RuntimeModel

ModelSchema

Gets the metadata schema of the sequence.

public virtual string? ModelSchema { get; }

Property Value

string

Name

Gets the name of the sequence in the database.

public virtual string Name { get; }

Property Value

string

Schema

Gets the database schema that contains the sequence.

public virtual string? Schema { get; }

Property Value

string

Methods

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

A string that represents the current object.