C# Class Griffin.Data.Sqlite.SqliteCommandBuilder

Inheritance: Griffin.Data.Mapper.CommandBuilders.CommandBuilder
Exibir arquivo Open project: jgauffin/Griffin.Framework Class Usage Examples

Public Methods

Method Description
InsertCommand ( IDbCommand command, object entity ) : void

Generate an insert command, should end with a command that returns the insert identity.

Last statement will return @@identity.

Paging ( IDbCommand command, int pageNumber, int pageSize ) : void

Uses the SQLite - LIMIT [pageSize] OFFSET [pageNumber] LIMIT [no of rows] OFFSET [row num]

SqliteCommandBuilder ( ICrudEntityMapper mapper ) : System.Data

Initializes a new instance of the SqliteCommandBuilder class.

TruncateCommand ( IDbCommand command ) : void

Truncate all rows in a table

Will do a DELETE statement and reset the identity sequence generator.

Method Details

InsertCommand() public method

Generate an insert command, should end with a command that returns the insert identity.
Last statement will return @@identity.
public InsertCommand ( IDbCommand command, object entity ) : void
command IDbCommand Command to add the query to
entity object Entity to store
return void

Paging() public method

Uses the SQLite - LIMIT [pageSize] OFFSET [pageNumber] LIMIT [no of rows] OFFSET [row num]
public Paging ( IDbCommand command, int pageNumber, int pageSize ) : void
command IDbCommand command to modify
pageNumber int One based index
pageSize int Items per page.
return void

SqliteCommandBuilder() public method

Initializes a new instance of the SqliteCommandBuilder class.
public SqliteCommandBuilder ( ICrudEntityMapper mapper ) : System.Data
mapper ICrudEntityMapper The mapper.
return System.Data

TruncateCommand() public method

Truncate all rows in a table
Will do a DELETE statement and reset the identity sequence generator.
public TruncateCommand ( IDbCommand command ) : void
command IDbCommand Command that will be executed after this method call
return void