Package play.db

Class DefaultDBApi

java.lang.Object
play.db.DefaultDBApi
All Implemented Interfaces:
DBApi

@Singleton public class DefaultDBApi extends Object implements DBApi
Default delegating implementation of the DB API.
  • Constructor Details

    • DefaultDBApi

      @Inject public DefaultDBApi(play.api.db.DBApi dbApi)
  • Method Details

    • getDatabases

      public List<Database> getDatabases()
      Specified by:
      getDatabases in interface DBApi
      Returns:
      all configured databases.
    • getDatabase

      public Database getDatabase(String name)
      Specified by:
      getDatabase in interface DBApi
      Parameters:
      name - the configuration name of the database
      Returns:
      Get database with given configuration name.
    • shutdown

      public void shutdown()
      Description copied from interface: DBApi
      Shutdown all databases, releasing resources.
      Specified by:
      shutdown in interface DBApi