Table of Contents

Class SqliteColumnBuilder

Namespace
LfrlAnvil.Sqlite.Objects.Builders
Assembly
LfrlAnvil.Sqlite.dll

Represents an SQL table column builder.

public sealed class SqliteColumnBuilder : SqlColumnBuilder, ISqlColumnBuilder, ISqlObjectBuilder
Inheritance
SqliteColumnBuilder
Implements
Inherited Members
Extension Methods

Remarks

SqliteDialect implementation.

Properties

Database

Database that this object belongs to.

public SqliteDatabaseBuilder Database { get; }

Property Value

SqliteDatabaseBuilder

Table

Table that this column belongs to.

public SqliteTableBuilder Table { get; }

Property Value

SqliteTableBuilder

Methods

MarkAsNullable(bool)

Changes IsNullable value of this column.

public SqliteColumnBuilder MarkAsNullable(bool enabled = true)

Parameters

enabled bool

Value to set. Equal to true by default.

Returns

SqliteColumnBuilder

this.

Exceptions

SqlObjectBuilderException

When nullability cannot be changed.

SetComputation(SqlColumnComputation?)

Changes Computation value of this column.

public SqliteColumnBuilder SetComputation(SqlColumnComputation? computation)

Parameters

computation SqlColumnComputation?

Value to set.

Returns

SqliteColumnBuilder

this.

Remarks

Changing the computation to non-null will reset the DefaultValue to null.

Exceptions

SqlObjectBuilderException

When computation cannot be changed.

SetDefaultValue(SqlExpressionNode?)

Changes DefaultValue value of this column.

public SqliteColumnBuilder SetDefaultValue(SqlExpressionNode? value)

Parameters

value SqlExpressionNode

Value to set.

Returns

SqliteColumnBuilder

this.

Exceptions

SqlObjectBuilderException

When default value cannot be changed.

SetIdentity(SqlColumnIdentity?)

Changes Identity value of this column.

public SqliteColumnBuilder SetIdentity(SqlColumnIdentity? identity)

Parameters

identity SqlColumnIdentity?

Value to set.

Returns

SqliteColumnBuilder

this.

Remarks

Changing the identity to non-null will reset the DefaultValue and Computation to null, and set IsNullable to false.

Exceptions

SqlObjectBuilderException

When identity cannot be changed.

SetName(string)

Changes the name of this object.

public SqliteColumnBuilder SetName(string name)

Parameters

name string

Name to set.

Returns

SqliteColumnBuilder

this.

Exceptions

SqlObjectBuilderException

When name cannot be changed.

SetType(SqlColumnTypeDefinition)

Changes TypeDefinition value of this column.

public SqliteColumnBuilder SetType(SqlColumnTypeDefinition definition)

Parameters

definition SqlColumnTypeDefinition

Value to set.

Returns

SqliteColumnBuilder

this.

Remarks

Changing the type will reset the DefaultValue to null.

Exceptions

SqlObjectBuilderException

When type definition cannot be changed.

ToString()

Returns a string representation of this SqliteColumnBuilder instance.

[Pure]
public override string ToString()

Returns

string

String representation.