Package com.jk.data.datasource.impl
Class JKPlainDataSource
java.lang.Object
com.jk.data.datasource.impl.JKAbstractDataSource
com.jk.data.datasource.impl.JKHibernateDataSource
com.jk.data.datasource.impl.JKPlainDataSource
- All Implemented Interfaces:
Synchronizable
,JKDataSource
This class extends
JKHibernateDataSource
and provides a specialized
data source for plain JDBC connections.- Version:
- 1.0
- Author:
- Dr. Jalal H. Kiswani
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String[]
Represents the array of properties to ignore during processing.Fields inherited from class com.jk.data.datasource.impl.JKAbstractDataSource
logger
-
Constructor Summary
ConstructorsConstructorDescriptionJKPlainDataSource
(String name, Properties properties) This method constructs a newJKPlainDataSource
with a name and configuration properties. -
Method Summary
Modifier and TypeMethodDescriptionprotected DataSource
This method creates and returns a plain JDBC data source based on the provided database URL, user name, and password.protected Map
This method gets extra Hibernate configuration settings.protected void
processProperty
(Properties properties, String key, String value) This method processes a property and its value.Methods inherited from class com.jk.data.datasource.impl.JKHibernateDataSource
close, close, createConnection, createEntityManager, createHibernateConfig, getNamingStrategy, getSessionFactory, guessMissingProperties, init, initConnectinoPool, initHibernate
Methods inherited from class com.jk.data.datasource.impl.JKAbstractDataSource
cleanSpecificDatabaseResources, close, close, fixProperties, getClientInfoProperties, getConfig, getConnection, getDatabaseType, getEmf, getEntities, getEntities, getMaxAllowedConnections, getName, getProperties, getQueryConnection, initProperties, isEntityAvailable, scanJpaEntities, setEmf, setName, setProperty, setPropertyIfNull
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.jk.data.datasource.JKDataSource
getBaseScriptPath, getDatabaseName, getDatabasepassword, getDatabaseUrl, getDatabaseUsername, getRowsLimit
-
Field Details
-
PROPERTIES_TO_IGNORE
Represents the array of properties to ignore during processing.
-
-
Constructor Details
-
JKPlainDataSource
This method constructs a newJKPlainDataSource
with a name and configuration properties.- Parameters:
name
- Specifies the data source name.properties
- Specifies the configuration properties.
-
-
Method Details
-
processProperty
This method processes a property and its value.- Overrides:
processProperty
in classJKHibernateDataSource
- Parameters:
properties
- Specifies the properties to process.key
- Specifies the key of the property.value
- Specifies the value of the property.
-
getHibernateExtraConfig
This method gets extra Hibernate configuration settings.Subclasses can override this method to provide additional configuration.
- Overrides:
getHibernateExtraConfig
in classJKHibernateDataSource
- Returns:
- the extra Hibernate configuration settings.
-
createPlainDataSource
This method creates and returns a plain JDBC data source based on the provided database URL, user name, and password.- Returns:
- the plain JDBC data source.
-