Table of Contents

Class MySqlPrimaryKeyBuilder

Namespace
LfrlAnvil.MySql.Objects.Builders
Assembly
LfrlAnvil.MySql.dll

Represents an SQL primary key constraint builder.

public sealed class MySqlPrimaryKeyBuilder : SqlPrimaryKeyBuilder, ISqlPrimaryKeyBuilder, ISqlConstraintBuilder, ISqlObjectBuilder
Inheritance
MySqlPrimaryKeyBuilder
Implements
Inherited Members
Extension Methods

Remarks

MySqlDialect implementation.

Properties

Database

Database that this object belongs to.

public MySqlDatabaseBuilder Database { get; }

Property Value

MySqlDatabaseBuilder

Index

Underlying index that defines this primary key.

public MySqlIndexBuilder Index { get; }

Property Value

MySqlIndexBuilder

Table

Table that this constraint is attached to.

public MySqlTableBuilder Table { get; }

Property Value

MySqlTableBuilder

Methods

SetDefaultName()

Changes the name of this object to a default name.

public MySqlPrimaryKeyBuilder SetDefaultName()

Returns

MySqlPrimaryKeyBuilder

this.

Remarks

See ISqlDefaultObjectNameProvider for more information.

Exceptions

SqlObjectBuilderException

When name cannot be changed.

SetName(string)

Changes the name of this object.

public MySqlPrimaryKeyBuilder SetName(string name)

Parameters

name string

Name to set.

Returns

MySqlPrimaryKeyBuilder

this.

Exceptions

SqlObjectBuilderException

When name cannot be changed.