com.googlecode.jdbw.server.h2
Class H2FileBasedServer

java.lang.Object
  extended by com.googlecode.jdbw.server.AbstractDatabaseServer
      extended by com.googlecode.jdbw.server.h2.H2FileBasedServer
All Implemented Interfaces:
DatabaseServer, H2Server

public class H2FileBasedServer
extends AbstractDatabaseServer
implements H2Server

Author:
Martin Berglund

Constructor Summary
H2FileBasedServer(String databaseFilePrefix)
           
 
Method Summary
 DatabaseConnection connect()
           
 DatabaseConnection connect(DataSourceFactory dataSourceFactory)
          Created a new DataSource to this server and returns it wrapped in a DatabaseConnection
protected  String getJDBCUrl()
           
 DatabaseServerType getServerType()
           
 
Methods inherited from class com.googlecode.jdbw.server.AbstractDatabaseServer
getConnectionProperties, getDriverDescriptor, setConnectionProperty, testConnection
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.googlecode.jdbw.DatabaseServer
setConnectionProperty, testConnection
 

Constructor Detail

H2FileBasedServer

public H2FileBasedServer(String databaseFilePrefix)
Method Detail

getJDBCUrl

protected String getJDBCUrl()
Specified by:
getJDBCUrl in class AbstractDatabaseServer

getServerType

public DatabaseServerType getServerType()
Specified by:
getServerType in interface DatabaseServer
Returns:
Type of the server

connect

public DatabaseConnection connect()

connect

public DatabaseConnection connect(DataSourceFactory dataSourceFactory)
Description copied from interface: DatabaseServer
Created a new DataSource to this server and returns it wrapped in a DatabaseConnection

Specified by:
connect in interface DatabaseServer
Overrides:
connect in class AbstractDatabaseServer
Parameters:
dataSourceFactory - Factory to use when creating the DataSource
Returns:
DatabaseConnection connected to the server


Copyright © 2012. All Rights Reserved.