Table of Contents

Class QueryBuilderExtensions

Namespace
Rinku
Assembly
Rinku.dll

Runs a query off an in-memory QueryBuilder. Once the builder holds the values you want, these methods turn them into a command on a connection and execute it, in the same shapes the command's own execution methods offer.

public static class QueryBuilderExtensions
Inheritance
QueryBuilderExtensions
Inherited Members

Methods

GetCommand<T>(T, object?[], DbConnection, DbTransaction?, int?)

Builds a fresh command on cnn for the current builder values. Useful when you want the command in hand rather than running it through one of the execution methods.

public static DbCommand GetCommand<T>(T command, object?[] variables, DbConnection cnn, DbTransaction? transaction = null, int? timeout = null) where T : IQueryCommand

Parameters

command T

The command whose text and parameters are produced from the values.

variables object[]

The builder values driving the command.

cnn DbConnection

The connection to create the command on.

transaction DbTransaction

The transaction to enlist, if any.

timeout int?

The command timeout, if set.

Returns

DbCommand

A command ready to run.

Type Parameters

T

GetCommand<T>(T, object?[], IDbConnection, IDbTransaction?, int?)

Builds a fresh command on cnn for the current builder values. Useful when you want the command in hand rather than running it through one of the execution methods.

public static IDbCommand GetCommand<T>(T command, object?[] variables, IDbConnection cnn, IDbTransaction? transaction = null, int? timeout = null) where T : IQueryCommand

Parameters

command T

The command whose text and parameters are produced from the values.

variables object[]

The builder values driving the command.

cnn IDbConnection

The connection to create the command on.

transaction IDbTransaction

The transaction to enlist, if any.

timeout int?

The command timeout, if set.

Returns

IDbCommand

A command ready to run.

Type Parameters

T