Below are the methods available from this class.
Add- adds a mapping between the IStatementBuilder and the type of the
Clear- clears all the mappings for the statement builders.
Get- gets the mapped IStatementBuilder based on the type of the
Remove- removed the mapping between the IStatementBuilder and the type of the
You should use this class if you would like to override the default mapping of the library when it comes to database statement building.
How to Use?
To add a mapping, simply call the
StatementBuilderMapper.Add<SqlConnection>(new OptimizedSqlServerStatementBuilder(), true);
An exception will be thrown if the mapping is already exists and you passed a
falsevalue in the
To get the mapping, use the
var statementBuilder = StatementBuilderMapper.Get<SqlConnection>();
To remove the mapping, use the