C# Class LX.EasyDb.Mapping.RelationalModel

Base class of relational models.
Inheritance: IRelationalModel
显示文件 Open project: longshine/EasyDb.NET

Public Methods

Method Description
AddColumn ( Column column ) : void

Adds an associated column.

AddColumns ( IEnumerable columns ) : void

Adds associated columns.

ContainsColumn ( Column column ) : System.Boolean

Checks if a column is associated with this model.

ToSqlCreate ( Dialect dialect, String defaultCatalog, String defaultSchema ) : String

Generates SQL for creating this model.

ToSqlDrop ( Dialect dialect, String defaultCatalog, String defaultSchema ) : String

Generates SQL for creating this model.

Protected Methods

Method Description
DoToSqlCreate ( Dialect dialect, String defaultCatalog, String defaultSchema ) : String

Generates SQL for creating this model.

DoToSqlDrop ( Dialect dialect, String defaultCatalog, String defaultSchema ) : String

Generates SQL for creating this model.

Method Details

AddColumn() public method

Adds an associated column.
public AddColumn ( Column column ) : void
column Column
return void

AddColumns() public method

Adds associated columns.
public AddColumns ( IEnumerable columns ) : void
columns IEnumerable
return void

ContainsColumn() public method

Checks if a column is associated with this model.
public ContainsColumn ( Column column ) : System.Boolean
column Column
return System.Boolean

DoToSqlCreate() protected abstract method

Generates SQL for creating this model.
protected abstract DoToSqlCreate ( Dialect dialect, String defaultCatalog, String defaultSchema ) : String
dialect Dialect
defaultCatalog String the default catalog name
defaultSchema String the default schema name
return String

DoToSqlDrop() protected abstract method

Generates SQL for creating this model.
protected abstract DoToSqlDrop ( Dialect dialect, String defaultCatalog, String defaultSchema ) : String
dialect Dialect
defaultCatalog String the default catalog name
defaultSchema String the default schema name
return String

ToSqlCreate() public method

Generates SQL for creating this model.
public ToSqlCreate ( Dialect dialect, String defaultCatalog, String defaultSchema ) : String
dialect Dialect
defaultCatalog String the default catalog name
defaultSchema String the default schema name
return String

ToSqlDrop() public method

Generates SQL for creating this model.
public ToSqlDrop ( Dialect dialect, String defaultCatalog, String defaultSchema ) : String
dialect Dialect
defaultCatalog String the default catalog name
defaultSchema String the default schema name
return String