Table of Contents

Class OperationBuilder<TOperation>

Namespace
Microsoft.EntityFrameworkCore.Migrations.Operations.Builders
Assembly
Microsoft.EntityFrameworkCore.Relational.dll

A builder for MigrationOperations.

public class OperationBuilder<TOperation> : IInfrastructure<TOperation> where TOperation : MigrationOperation

Type Parameters

TOperation

The type of MigrationOperation to build for.

Inheritance
OperationBuilder<TOperation>
Implements
IInfrastructure<TOperation>
Derived
Inherited Members

Constructors

OperationBuilder(TOperation)

Creates a new builder instance for the given MigrationOperation.

public OperationBuilder(TOperation operation)

Parameters

operation TOperation

The MigrationOperation.

Properties

Operation

protected virtual TOperation Operation { get; }

Property Value

TOperation

Methods

Annotation(string, object)

Annotates the operation with the given name/value pair.

public virtual OperationBuilder<TOperation> Annotation(string name, object value)

Parameters

name string

The annotation name.

value object

The annotation value.

Returns

OperationBuilder<TOperation>

The same builder so that multiple calls can be chained.