Module: Rooq::Adapters::PostgreSQL
- Defined in:
- lib/rooq/adapters/postgresql.rb
Defined Under Namespace
Classes: ConnectionPool
Class Method Summary collapse
-
.context(connection) ⇒ Rooq::Context
Create a Context configured for PostgreSQL.
-
.pooled_context(pool) ⇒ Rooq::Context
Create a Context with a connection pool.
Class Method Details
.context(connection) ⇒ Rooq::Context
Create a Context configured for PostgreSQL.
105 106 107 |
# File 'lib/rooq/adapters/postgresql.rb', line 105 def self.context(connection) Rooq::Context.using(connection, dialect: Rooq::Dialect::PostgreSQL.new) end |
.pooled_context(pool) ⇒ Rooq::Context
Create a Context with a connection pool.
112 113 114 |
# File 'lib/rooq/adapters/postgresql.rb', line 112 def self.pooled_context(pool) Rooq::Context.using_pool(pool, dialect: Rooq::Dialect::PostgreSQL.new) end |