C# Class Dibware.StoredProcedureFramework.Base.StoredProcedureSqlConnection

Represents a base class that may be inherited for use with an application specific connection
Inheritance: System.Data.Common.DbConnection, IDisposable
Mostra file Open project: dibley1973/StoredProcedureFramework

Private Properties

Property Type Description
Dispose void

Public Methods

Method Description
ChangeDatabase ( string databaseName ) : void

Changes the current database for an open connection.

Close ( ) : void

Closes the connection to the database. This is the preferred method of closing any open connection.

Dispose ( ) : void

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

Open ( ) : void

Opens a database connection with the settings specified by the P:System.Data.Common.DbConnection.ConnectionString.

Protected Methods

Method Description
BeginDbTransaction ( IsolationLevel isolationLevel ) : DbTransaction

Starts a database transaction.

CreateDbCommand ( ) : DbCommand

Creates and returns a T:System.Data.Common.DbCommand object associated with the current connection.

StoredProcedureSqlConnection ( string connectionString ) : System

Initializes a new instance of the StoredProcedureSqlConnection class.

Private Methods

Method Description
Dispose ( bool disposing ) : void

Releases unmanaged and - optionally - managed resources.

Method Details

BeginDbTransaction() protected method

Starts a database transaction.
protected BeginDbTransaction ( IsolationLevel isolationLevel ) : DbTransaction
isolationLevel IsolationLevel Specifies the isolation level for the transaction.
return System.Data.Common.DbTransaction

ChangeDatabase() public method

Changes the current database for an open connection.
public ChangeDatabase ( string databaseName ) : void
databaseName string Specifies the name of the database for the connection to use.
return void

Close() public method

Closes the connection to the database. This is the preferred method of closing any open connection.
public Close ( ) : void
return void

CreateDbCommand() protected method

Creates and returns a T:System.Data.Common.DbCommand object associated with the current connection.
protected CreateDbCommand ( ) : DbCommand
return System.Data.Common.DbCommand

Dispose() public method

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
public Dispose ( ) : void
return void

Open() public method

Opens a database connection with the settings specified by the P:System.Data.Common.DbConnection.ConnectionString.
public Open ( ) : void
return void

StoredProcedureSqlConnection() protected method

Initializes a new instance of the StoredProcedureSqlConnection class.
protected StoredProcedureSqlConnection ( string connectionString ) : System
connectionString string The connection string.
return System