Class DbConnectionFactoryExtensions
- Namespace
- Open.Database.Extensions
- Assembly
- Open.Database.Extensions.Core.dll
Extensions for presenting a connection factory as a pool or as a generic factory.
public static class DbConnectionFactoryExtensions
- Inheritance
-
DbConnectionFactoryExtensions
- Inherited Members
Methods
- AsGeneric(IDbConnectionFactory)
Converts a non-generic connection factory to a generic one.
- AsPool(IDbConnectionFactory)
Presents a connection factory as a connection pool that creates a new connection when one is taken and disposes it when it is given back.
- AsPool(Func<IDbConnection>)
Presents a connection factory function as a connection pool that invokes the function when a connection is taken and disposes the connection when it is given back.
- AsPool<TConnection>(IDbConnectionFactory<TConnection>)
Presents a typed connection factory as a connection pool that creates a new connection when one is taken and disposes it when it is given back.
- AsPool<TConnection>(Func<TConnection>)
Presents a typed connection factory function as a connection pool that invokes the function when a connection is taken and disposes the connection when it is given back.