Interface ConnectionProvider<APIType extends DatabaseAPI>

Type Parameters:
APIType - The type of the higher-level access interface that can be used to work with the database this class makes connections to.
All Known Implementing Classes:
BufferManagerDatabaseEngine, DatabaseEngine, DSEDatabaseEngine

public interface ConnectionProvider<APIType extends DatabaseAPI>
Indicates a class that can provide database connections to suitably-configured databases.
Author:
Donal Fellows
  • Method Details

    • getConnection

      Connection getConnection() throws SQLException
      Get a connection to a database, creating it if needed.
      Returns:
      The configured connection to the database. The database will have been seeded with DDL if necessary.
      Throws:
      SQLException - If anything goes wrong.
    • getStorageInterface

      APIType getStorageInterface()
      Returns:
      a storage interface that is suitable for providing support for a particular API.