Class DatabaseEngine<APIType extends DatabaseAPI>

java.lang.Object
uk.ac.manchester.spinnaker.storage.DatabaseEngine<APIType>
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 Implemented Interfaces:
ConnectionProvider<APIType>
Direct Known Subclasses:
BufferManagerDatabaseEngine, DSEDatabaseEngine

public abstract class DatabaseEngine<APIType extends DatabaseAPI>
extends Object
implements ConnectionProvider<APIType>
The database engine interface. Based on SQLite.

Note that these database interfaces have their synchronisation mode set to OFF; they are not resistant to system crashes in any way, but they are faster when dealing with write-heavy workloads (particularly important for the BufferManagerDatabaseEngine).

Author:
Donal Fellows
  • Constructor Details

    • DatabaseEngine

      protected DatabaseEngine()
      Create an engine interface for an in-memory database.
    • DatabaseEngine

      protected DatabaseEngine​(File dbFile)
      Create an engine interface for a particular database.
      Parameters:
      dbFile - The file containing the database.
    • DatabaseEngine

      protected DatabaseEngine​(URI dbUri)
      Create an engine interface for a particular database.
      Parameters:
      dbUri - The absolute URI to the file containing the database. May contain query parameters as documented.
      Throws:
      IllegalArgumentException - If the URI is of an unsupported type.
  • Method Details