Class StoredProcedureBase<TParameters>
Provides a base class for different types of stored procedures.
Inheritance
Namespace: Paradigm.ORM.Data.StoredProcedures
Assembly: Paradigm.ORM.Data.dll
Syntax
public abstract class StoredProcedureBase<TParameters> : object, IRoutine, IDisposable
Type Parameters
| Name | Description |
|---|---|
| TParameters | The type of the parameters. |
Constructors
| Improve this Doc View SourceStoredProcedureBase(IServiceProvider)
Initializes a new instance of the StoredProcedureBase<TParameters> class.
Declaration
protected StoredProcedureBase(IServiceProvider serviceProvider)
Parameters
| Type | Name | Description |
|---|---|---|
| IServiceProvider | serviceProvider | The service provider. |
StoredProcedureBase(IServiceProvider, IDatabaseConnector)
Initializes a new instance of the StoredProcedureBase<TParameters> class.
Declaration
protected StoredProcedureBase(IServiceProvider serviceProvider, IDatabaseConnector connector)
Parameters
| Type | Name | Description |
|---|---|---|
| IServiceProvider | serviceProvider | The service provider. |
| IDatabaseConnector | connector | The database connector. |
StoredProcedureBase(IDatabaseConnector)
Initializes a new instance of the StoredProcedureBase<TParameters> class.
Declaration
protected StoredProcedureBase(IDatabaseConnector connector)
Parameters
| Type | Name | Description |
|---|---|---|
| IDatabaseConnector | connector | The database connector. |
Properties
| Improve this Doc View SourceCommand
Gets the routine caller command.
Declaration
public IDatabaseCommand Command { get; }
Property Value
| Type | Description |
|---|---|
| IDatabaseCommand |
Connector
Gets the database connector.
Declaration
protected IDatabaseConnector Connector { get; set; }
Property Value
| Type | Description |
|---|---|
| IDatabaseConnector |
ServiceProvider
Gets the service provider.
Declaration
protected IServiceProvider ServiceProvider { get; }
Property Value
| Type | Description |
|---|---|
| IServiceProvider |
Methods
| Improve this Doc View SourceAfterInitialize()
Executes after the initialization.
Declaration
protected virtual void AfterInitialize()
BeforeInitialize()
Executes before the initialization.
Declaration
protected virtual void BeforeInitialize()
Dispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
Declaration
public void Dispose()
GetRoutineName()
Gets the name of the Routine already scaped.
Declaration
protected string GetRoutineName()
Returns
| Type | Description |
|---|---|
| System.String | The name of the Routine. |
SetParametersValue(TParameters)
Sets the command parameters using the parameter property values.
Declaration
protected void SetParametersValue(TParameters parameters)
Parameters
| Type | Name | Description |
|---|---|---|
| TParameters | parameters | The parameters. |