public class DomainObjectFactory<T> extends AbstractDomainObjectFactory<T>
Modifier and Type | Field and Description |
---|---|
protected java.lang.String |
catalog
Target DB catalog
|
protected DBServices |
dbServices
This is JDBC utility
|
protected boolean |
generateSQLOnly
Do not execute INSERTS/UPDATES/DELETES - just generate SQL and parameters
|
protected boolean |
noFullColumnName
Some databases (like hsqldb) fail when UPDATE/INSERT statements are using
TABLE_NAME.COLUMN_NAME in SET clause.
|
protected boolean |
overrideCatalogName
If overrideCatalogName == true and catalog from this.metaData is null
than use catalog member variable
|
protected java.lang.String |
schema
Target DB schema
|
protected java.lang.String |
table
Target DB Table
|
protected boolean |
throwFailedInsertException |
protected boolean |
throwOptimisticLockDeleteException
Throw exception if PreparedStatement.executeUpdate() does not return 1
for each DomainObject.
|
protected boolean |
throwOptimisticLockUpdateException |
append, createDefaultMetaData, dataReader, dataWriter, discardUnmodifiedObjects, domainClass, domainFactoryId, EMPTY_ARG, exceptionOnEmptyObjectList, instantiator, internalId, lazyLoading, listeners, mapping, metaData, objectList, options, readOnly, removedObjects, throwMissingFieldException, valid
Constructor and Description |
---|
DomainObjectFactory() |
Modifier and Type | Method and Description |
---|---|
DataReader<T> |
getDataReader()
Getter for property dataReader.
|
DataWriter<T> |
getDataWriter()
Getter for property dataWriter.
|
DBServices |
getDBServices() |
void |
populateMetaData() |
void |
setDBServices(DBServices dbServices) |
<UID> void |
setUniqueId(T domainObject,
java.lang.Class<UID> uidClass)
if parameter uidClass is not null than it must be a java bean with getters/setters for properties with the same
name as properties in domainObject used as unique values
if parameter uidClass is null than if PrimaryKey is multicolumn an Object array is used, otherwise an Object.
|
boolean |
writeData()
Implement and call this method to persist data
|
addObject, addObject, addPropertyChangeListeners, afterCreate, afterRemove, afterStore, afterWriteData, attach, attach, beforeCreate, beforeRemove, beforeStore, beforeWriteData, clearData, create, createOriginalValues, detach, detach, detachAll, detachAll, discard, filter, findIdxByInternalId, findIdxByInternalId, findObjectByInternalId, findObjectByInternalId, getCreatedCount, getDomainClass, getMapping, getMetaData, getModifiedCount, getNextInternalId, getObjectList, getObjects, getOptions, getPersistenceError, getRemovedCount, getRemovedObjects, init, isAppend, isCreateDefaultMetaData, isDiscardUnmodifiedObjects, isExceptionOnEmptyObjectList, isLazyLoading, isReadOnly, isThrowMissingFieldException, isValid, load, load, load, load, loadMappings, loadProperties, newInstance, readValue, remove, removePropertyChangeListeners, setAppend, setCreateDefaultMetaData, setDataReader, setDataWriter, setDiscardUnmodifiedObjects, setDomainClass, setExceptionOnEmptyObjectList, setLazyLoading, setMapping, setMapping, setMetaData, setObject, setObject, setObjectList, setOptions, setOriginal, setReadOnly, setRemovedObjects, setThrowMissingFieldException, setupEnhancedObject, store, synchronizePersistentState, syncOriginal, toString, writeValue
protected boolean throwOptimisticLockDeleteException
protected boolean throwOptimisticLockUpdateException
protected boolean throwFailedInsertException
protected java.lang.String catalog
protected boolean overrideCatalogName
protected java.lang.String schema
protected java.lang.String table
protected DBServices dbServices
protected boolean generateSQLOnly
protected boolean noFullColumnName
public DBServices getDBServices()
public void setDBServices(DBServices dbServices)
public DataWriter<T> getDataWriter()
AbstractDomainObjectFactory
getDataWriter
in class AbstractDomainObjectFactory<T>
public DataReader<T> getDataReader()
AbstractDomainObjectFactory
getDataReader
in class AbstractDomainObjectFactory<T>
public boolean writeData()
AbstractDomainObjectFactory
writeData
in class AbstractDomainObjectFactory<T>
public void populateMetaData()
populateMetaData
in class AbstractDomainObjectFactory<T>
public <UID> void setUniqueId(T domainObject, java.lang.Class<UID> uidClass)
AbstractDomainObjectFactory
setUniqueId
in class AbstractDomainObjectFactory<T>