Craig's Utility Library  4.0 Beta
Utilities.ORM.Manager.QueryProvider.Default.DatabaseBatch Class Reference

Database batch class More...

Inheritance diagram for Utilities.ORM.Manager.QueryProvider.Default.DatabaseBatch:
Utilities.ORM.Manager.QueryProvider.Interfaces.IBatch

Public Member Functions

 DatabaseBatch (ISourceInfo Source)
 Constructor More...
 
IBatch AddCommand (Action< Command, IList< dynamic >> CallBack, object Object, CommandType CommandType, string Command)
 Adds a command to be batched More...
 
IBatch AddCommand (Action< Command, IList< dynamic >> CallBack, object Object, string Command, CommandType CommandType, params object[] Parameters)
 Adds a command to be batched More...
 
IBatch AddCommand (Action< Command, IList< dynamic >> CallBack, object Object, string Command, CommandType CommandType, params IParameter[] Parameters)
 Adds a command to be batched More...
 
IBatch AddCommand (IBatch Batch)
 Adds a batch's commands to the current batch More...
 
IList< IList< dynamic > > Execute ()
 Executes the commands and returns the results More...
 
IBatch RemoveDuplicateCommands ()
 Removes duplicate commands from the batch More...
 
override string ToString ()
 Converts the batch to a string More...
 

Properties

int CommandCount [get]
 Command count More...
 
IList< CommandCommands [get]
 Commands to batch More...
 
ISourceInfo Source [get, set]
 Connection string More...
 
- Properties inherited from Utilities.ORM.Manager.QueryProvider.Interfaces.IBatch
int CommandCount [get]
 Number of commands being batched More...
 

Detailed Description

Database batch class

Definition at line 39 of file DatabaseBatch.cs.

Constructor & Destructor Documentation

Utilities.ORM.Manager.QueryProvider.Default.DatabaseBatch.DatabaseBatch ( ISourceInfo  Source)

Constructor

Parameters
SourceSource info

Definition at line 45 of file DatabaseBatch.cs.

Member Function Documentation

IBatch Utilities.ORM.Manager.QueryProvider.Default.DatabaseBatch.AddCommand ( Action< Command, IList< dynamic >>  CallBack,
object  Object,
CommandType  CommandType,
string  Command 
)

Adds a command to be batched

Parameters
CommandCommand (SQL or stored procedure) to run
CommandTypeCommand type
CallBackCallback action
ObjectObject used in the callback action
Returns
This

Implements Utilities.ORM.Manager.QueryProvider.Interfaces.IBatch.

Definition at line 79 of file DatabaseBatch.cs.

IBatch Utilities.ORM.Manager.QueryProvider.Default.DatabaseBatch.AddCommand ( Action< Command, IList< dynamic >>  CallBack,
object  Object,
string  Command,
CommandType  CommandType,
params object[]  Parameters 
)

Adds a command to be batched

Parameters
CommandCommand (SQL or stored procedure) to run
CommandTypeCommand type
ParametersParameters to add
CallBackCallback action
ObjectObject used in the callback action
Returns
This

Implements Utilities.ORM.Manager.QueryProvider.Interfaces.IBatch.

Definition at line 94 of file DatabaseBatch.cs.

IBatch Utilities.ORM.Manager.QueryProvider.Default.DatabaseBatch.AddCommand ( Action< Command, IList< dynamic >>  CallBack,
object  Object,
string  Command,
CommandType  CommandType,
params IParameter[]  Parameters 
)

Adds a command to be batched

Parameters
CommandCommand (SQL or stored procedure) to run
CommandTypeCommand type
ParametersParameters to add
CallBackCallback action
ObjectObject used in the callback action
Returns
This

Implements Utilities.ORM.Manager.QueryProvider.Interfaces.IBatch.

Definition at line 109 of file DatabaseBatch.cs.

IBatch Utilities.ORM.Manager.QueryProvider.Default.DatabaseBatch.AddCommand ( IBatch  Batch)

Adds a batch's commands to the current batch

Parameters
BatchBatch to add
Returns
This

Implements Utilities.ORM.Manager.QueryProvider.Interfaces.IBatch.

Definition at line 120 of file DatabaseBatch.cs.

IList<IList<dynamic> > Utilities.ORM.Manager.QueryProvider.Default.DatabaseBatch.Execute ( )

Executes the commands and returns the results

Returns
The results of the batched commands

Implements Utilities.ORM.Manager.QueryProvider.Interfaces.IBatch.

Definition at line 133 of file DatabaseBatch.cs.

IBatch Utilities.ORM.Manager.QueryProvider.Default.DatabaseBatch.RemoveDuplicateCommands ( )

Removes duplicate commands from the batch

Returns
This

Implements Utilities.ORM.Manager.QueryProvider.Interfaces.IBatch.

Definition at line 142 of file DatabaseBatch.cs.

override string Utilities.ORM.Manager.QueryProvider.Default.DatabaseBatch.ToString ( )

Converts the batch to a string

Returns

Definition at line 152 of file DatabaseBatch.cs.

Property Documentation

int Utilities.ORM.Manager.QueryProvider.Default.DatabaseBatch.CommandCount
get

Command count

Definition at line 54 of file DatabaseBatch.cs.

IList<Command> Utilities.ORM.Manager.QueryProvider.Default.DatabaseBatch.Commands
getprotected

Commands to batch

Definition at line 59 of file DatabaseBatch.cs.

ISourceInfo Utilities.ORM.Manager.QueryProvider.Default.DatabaseBatch.Source
getsetprotected

Connection string

Definition at line 64 of file DatabaseBatch.cs.


The documentation for this class was generated from the following file: