org.sonar.core.persistence
Class DefaultDatabase

java.lang.Object
  extended by org.sonar.core.persistence.DefaultDatabase
All Implemented Interfaces:
Database
Direct Known Subclasses:
BatchDatabase

public class DefaultDatabase
extends Object
implements Database

Since:
2.12

Constructor Summary
DefaultDatabase(Settings settings)
           
 
Method Summary
protected  void doBeforeStart()
           
protected  void doBeforeStop()
           
protected  void doCompleteProperties(Properties properties)
           
 DataSource getDataSource()
          Returns the configured datasource.
 Dialect getDialect()
           
 Properties getHibernateProperties()
           
 Properties getProperties()
           
 String getSchema()
           
 DefaultDatabase start()
           
 DefaultDatabase stop()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultDatabase

public DefaultDatabase(Settings settings)
Method Detail

start

public final DefaultDatabase start()
Specified by:
start in interface Database

doBeforeStart

protected void doBeforeStart()

stop

public final DefaultDatabase stop()
Specified by:
stop in interface Database

doBeforeStop

protected void doBeforeStop()

getDialect

public final Dialect getDialect()
Specified by:
getDialect in interface Database
Returns:
the dialect or null if start() has not been executed

getSchema

public final String getSchema()
Specified by:
getSchema in interface Database

getHibernateProperties

public Properties getHibernateProperties()
Specified by:
getHibernateProperties in interface Database

getDataSource

public final DataSource getDataSource()
Description copied from interface: Database
Returns the configured datasource. Null as long as start() is not executed.

Specified by:
getDataSource in interface Database

getProperties

public final Properties getProperties()

doCompleteProperties

protected void doCompleteProperties(Properties properties)


Copyright © 2009-2012 SonarSource. All Rights Reserved.