Class DbAdaptorFactory

java.lang.Object
ru.curs.celesta.dbutils.adaptors.configuration.DbAdaptorFactory

public final class DbAdaptorFactory extends Object
DB adaptor builder.

Depending on DB type the following descendants of DBAdaptor are returned:
  • Constructor Details

    • DbAdaptorFactory

      public DbAdaptorFactory()
  • Method Details

    • setDbType

      public DbAdaptorFactory setDbType(DBType dbType)
      Sets DB type.
      Parameters:
      dbType - DB type
      Returns:
      this
    • setDdlConsumer

      public DbAdaptorFactory setDdlConsumer(DdlConsumer ddlConsumer)
      Sets DDL Consumer.
      Parameters:
      ddlConsumer - DDL consumer
      Returns:
      @return this
    • setConnectionPool

      public DbAdaptorFactory setConnectionPool(ConnectionPool connectionPool)
      Sets Connection pool.
      Parameters:
      connectionPool - connection pool
      Returns:
      @return this
    • setH2ReferentialIntegrity

      public DbAdaptorFactory setH2ReferentialIntegrity(boolean h2ReferentialIntegrity)
      Whether referential integrity for H2 DB has to be switched on/off.
      Parameters:
      h2ReferentialIntegrity - true - switch on, false - switch off. Defaul value is false.
      Returns:
    • createDbAdaptor

      public DBAdaptor createDbAdaptor()
      Builds DB adaptor for concrete DB type.
      Returns: