Package play.db
Interface ConnectionPool
-
- All Known Implementing Classes:
DefaultConnectionPool
public interface ConnectionPool
Connection pool API for managing data sources.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description play.api.db.ConnectionPool
asScala()
void
close(DataSource dataSource)
Close the given data source.DataSource
create(String name, com.typesafe.config.Config configuration, Environment environment)
Create a data source with the given configuration.
-
-
-
Method Detail
-
create
DataSource create(String name, com.typesafe.config.Config configuration, Environment environment)
Create a data source with the given configuration.- Parameters:
name
- the database nameconfiguration
- the data source configurationenvironment
- the database environment- Returns:
- a data source backed by a connection pool
-
close
void close(DataSource dataSource)
Close the given data source.- Parameters:
dataSource
- the data source to close
-
asScala
play.api.db.ConnectionPool asScala()
- Returns:
- the Scala version for this connection pool.
-
-