2 * Copyright (C) 2007 EDIT
3 * European Distributed Institute of Taxonomy
4 * http://www.e-taxonomy.eu
6 * The contents of this file are subject to the Mozilla Public License Version 1.1
7 * See LICENSE.TXT at the top of this package for the full license terms.
10 package eu
.etaxonomy
.cdm
.database
.types
;
12 import org
.springframework
.jdbc
.datasource
.DriverManagerDataSource
;
14 import eu
.etaxonomy
.cdm
.database
.LocalHsqldb
;
21 public class HSqlDbDatabaseType
extends DatabaseTypeBase
{
24 private String typeName
= "Hypersonic SQL DB (HSqlDb)";
27 private String classString
= "org.hsqldb.jdbcDriver";
30 private String urlString
= "jdbc:hsqldb:hsql://";
33 private int defaultPort
= 9001;
36 private String hibernateDialect
= "HSQLDialect";
40 public String
getConnectionString(String server
, String database
, int port
){
41 return urlString
+ server
+ ":" + port
+ "/" + database
;
45 public HSqlDbDatabaseType() {
46 init (typeName
, classString
, urlString
, defaultPort
, hibernateDialect
);
50 public Class
<?
extends DriverManagerDataSource
> getDriverManagerDataSourceClass() {
51 return LocalHsqldb
.class;