C# Class Azavea.Open.DAO.SQL.DbCommandCache

Holds DbCommands, we save them to allow us to reuse them (saves time).
Datei anzeigen Open project: azavea/net-dao

Public Methods

Method Description
Get ( string sql, IDbConnection conn ) : IDbCommand

This returns a command from the cache, or creates a new one if necessary. This method is thread-safe.

Return ( string sql, IDbConnection conn, IDbCommand cmd ) : void

Returns a command to the cache when it is no longer used, allowing another call to reuse it. This method is thread-safe.

Method Details

Get() public method

This returns a command from the cache, or creates a new one if necessary. This method is thread-safe.
public Get ( string sql, IDbConnection conn ) : IDbCommand
sql string
conn IDbConnection
return IDbCommand

Return() public method

Returns a command to the cache when it is no longer used, allowing another call to reuse it. This method is thread-safe.
public Return ( string sql, IDbConnection conn, IDbCommand cmd ) : void
sql string
conn IDbConnection
cmd IDbCommand
return void