Class CreateBuilder
Inheritance
System.Object
Assembly: cs.temp.dll.dll
Syntax
public class CreateBuilder : ICreateBuilder, IFluentBuilder
Constructors
CreateBuilder(IMigrationContext)
Declaration
public CreateBuilder(IMigrationContext context)
Parameters
Methods
Column(String)
Builds a Create Column expression.
Declaration
public ICreateColumnOnTableBuilder Column(string columnName)
Parameters
Type |
Name |
Description |
System.String |
columnName |
|
Returns
Type |
Description |
ICreateColumnOnTableBuilder |
|
Constraint(String)
Builds a Create Constraint expression.
Declaration
public ICreateConstraintOnTableBuilder Constraint(string constraintName)
Parameters
Type |
Name |
Description |
System.String |
constraintName |
|
Returns
Type |
Description |
ICreateConstraintOnTableBuilder |
|
ForeignKey()
Builds a Create Foreign Key expression.
Declaration
public ICreateForeignKeyFromTableBuilder ForeignKey()
Returns
Type |
Description |
ICreateForeignKeyFromTableBuilder |
|
ForeignKey(String)
Builds a Create Foreign Key expression.
Declaration
public ICreateForeignKeyFromTableBuilder ForeignKey(string foreignKeyName)
Parameters
Type |
Name |
Description |
System.String |
foreignKeyName |
|
Returns
Type |
Description |
ICreateForeignKeyFromTableBuilder |
|
Index()
Builds a Create Index expression.
Declaration
public ICreateIndexForTableBuilder Index()
Returns
Type |
Description |
ICreateIndexForTableBuilder |
|
Index(String)
Builds a Create Index expression.
Declaration
public ICreateIndexForTableBuilder Index(string indexName)
Parameters
Type |
Name |
Description |
System.String |
indexName |
|
Returns
Type |
Description |
ICreateIndexForTableBuilder |
|
KeysAndIndexes(Type)
Builds a Create Keys and Indexes expression, and executes.
Declaration
public IExecutableBuilder KeysAndIndexes(Type typeOfDto)
Parameters
Type |
Name |
Description |
System.Type |
typeOfDto |
|
Returns
Type |
Description |
IExecutableBuilder |
|
KeysAndIndexes<TDto>()
Builds a Create Keys and Indexes expression, and executes.
Declaration
public IExecutableBuilder KeysAndIndexes<TDto>()
Returns
Type |
Description |
IExecutableBuilder |
|
Type Parameters
PrimaryKey()
Builds a Create Primary Key expression.
Declaration
public ICreateConstraintOnTableBuilder PrimaryKey()
Returns
Type |
Description |
ICreateConstraintOnTableBuilder |
|
PrimaryKey(Boolean)
Builds a Create Primary Key expression.
Declaration
public ICreateConstraintOnTableBuilder PrimaryKey(bool clustered)
Parameters
Type |
Name |
Description |
System.Boolean |
clustered |
|
Returns
Type |
Description |
ICreateConstraintOnTableBuilder |
|
PrimaryKey(String)
Builds a Create Primary Key expression.
Declaration
public ICreateConstraintOnTableBuilder PrimaryKey(string primaryKeyName)
Parameters
Type |
Name |
Description |
System.String |
primaryKeyName |
|
Returns
Type |
Description |
ICreateConstraintOnTableBuilder |
|
PrimaryKey(String, Boolean)
Builds a Create Primary Key expression.
Declaration
public ICreateConstraintOnTableBuilder PrimaryKey(string primaryKeyName, bool clustered)
Parameters
Type |
Name |
Description |
System.String |
primaryKeyName |
|
System.Boolean |
clustered |
|
Returns
Type |
Description |
ICreateConstraintOnTableBuilder |
|
Table(String)
Builds a Create Table expression.
Declaration
public ICreateTableWithColumnBuilder Table(string tableName)
Parameters
Type |
Name |
Description |
System.String |
tableName |
|
Returns
Type |
Description |
ICreateTableWithColumnBuilder |
|
Table<TDto>(Boolean)
Builds a Create Table expression, and executes.
Declaration
public IExecutableBuilder Table<TDto>(bool withoutKeysAndIndexes = false)
Parameters
Type |
Name |
Description |
System.Boolean |
withoutKeysAndIndexes |
|
Returns
Type |
Description |
IExecutableBuilder |
|
Type Parameters
UniqueConstraint()
Builds a Create Unique Constraint expression.
Declaration
public ICreateConstraintOnTableBuilder UniqueConstraint()
Returns
Type |
Description |
ICreateConstraintOnTableBuilder |
|
UniqueConstraint(String)
Builds a Create Unique Constraint expression.
Declaration
public ICreateConstraintOnTableBuilder UniqueConstraint(string constraintName)
Parameters
Type |
Name |
Description |
System.String |
constraintName |
|
Returns
Type |
Description |
ICreateConstraintOnTableBuilder |
|