public interface IDatabaseService
Modifier and Type | Method and Description |
---|---|
boolean |
connectToDatabase(DatabaseTypeEnum databaseTypeEnum,
java.lang.String server,
java.lang.String database,
java.lang.String username,
java.lang.String password)
Connect to the database with the given parameters.
|
boolean |
connectToDatabase(DatabaseTypeEnum databaseTypeEnum,
java.lang.String server,
java.lang.String database,
java.lang.String username,
java.lang.String password,
int port,
java.lang.String filePath,
H2Mode mode)
Connect to the database with the given parameters
|
boolean |
connectToDatasource(CdmPersistentDataSource dataSource)
Connect to the database with the given parameters.
|
java.util.Map<CdmMetaDataPropertyName,java.lang.String> |
getCdmMetadataMap() |
java.lang.String |
getDbSchemaVersion()
Returns the CDM model schema version number
|
java.lang.String |
getUrl()
Returns the database URL
|
java.lang.String |
getUsername()
Returns the username.
|
boolean |
isDbEmpty()
Returns a boolean flag to indicate whether the database is empty
|
CdmPersistentDataSource |
saveDataSource(java.lang.String strDataSourceName,
ICdmDataSource dataSource)
Saves a new ICdmDatasource into the datasource config file.
|
void |
setApplicationController(CdmApplicationController cdmApplicationController) |
CdmPersistentDataSource |
updateDataSource(java.lang.String strDataSourceName,
CdmPersistentDataSource dataSource)
Update an already saved datasource in datasource config file
|
java.lang.String getUrl()
java.lang.String getUsername()
boolean connectToDatabase(DatabaseTypeEnum databaseTypeEnum, java.lang.String server, java.lang.String database, java.lang.String username, java.lang.String password, int port, java.lang.String filePath, H2Mode mode) throws TermNotFoundException
databaseTypeEnum
- url
- username
- password
- port
- TermNotFoundException
boolean connectToDatabase(DatabaseTypeEnum databaseTypeEnum, java.lang.String server, java.lang.String database, java.lang.String username, java.lang.String password) throws TermNotFoundException
databaseTypeEnum
- url
- username
- password
- TermNotFoundException
boolean connectToDatasource(CdmPersistentDataSource dataSource) throws TermNotFoundException
dataSource
- TermNotFoundException
CdmPersistentDataSource saveDataSource(java.lang.String strDataSourceName, ICdmDataSource dataSource)
strDataSourceName
- dataSource
- code
- CdmPersistentDataSource updateDataSource(java.lang.String strDataSourceName, CdmPersistentDataSource dataSource) throws DataSourceNotFoundException
strDataSourceName
- the beanId under which the dataSource should be saveddataSource
- the dataSource to be savedDataSourceNotFoundException
void setApplicationController(CdmApplicationController cdmApplicationController)
cdmApplicationController
- java.lang.String getDbSchemaVersion() throws CdmSourceException
CdmSourceException
- , incase of an underlying SQL errorboolean isDbEmpty() throws CdmSourceException
CdmSourceException
- , incase of an underlying SQL errorjava.util.Map<CdmMetaDataPropertyName,java.lang.String> getCdmMetadataMap() throws CdmSourceException
CdmSourceException
Copyright © 2007-2020 EDIT. All Rights Reserved.