Package com.logicaldoc.barcode
Class HibernateBarcodeTemplateDAO
java.lang.Object
com.logicaldoc.core.HibernatePersistentObjectDAO<BarcodeTemplate>
com.logicaldoc.barcode.HibernateBarcodeTemplateDAO
- All Implemented Interfaces:
BarcodeTemplateDAO
,com.logicaldoc.core.PersistentObjectDAO<BarcodeTemplate>
public class HibernateBarcodeTemplateDAO
extends com.logicaldoc.core.HibernatePersistentObjectDAO<BarcodeTemplate>
implements BarcodeTemplateDAO
Hibernate implementation of
BarcodeTemplateDAO
- Since:
- 8.4.2
- Author:
- Marco Meschieri - LogicalDOC
-
Field Summary
Fields inherited from interface com.logicaldoc.core.PersistentObjectDAO
ENTITY
-
Method Summary
Modifier and TypeMethodDescriptionvoid
delete
(long templateId, int code) findByName
(String name, long tenantId) This method finds the ocr template by it's name(alternate key inside the tenant).findByTemplate
(Long templateId, Long tenantId) This method finds all the barcode templates assigned to the same template.void
initialize
(BarcodeTemplate template) void
store
(BarcodeTemplate template) Methods inherited from class com.logicaldoc.core.HibernatePersistentObjectDAO
bulkUpdate, delete, deleteAll, deleteAll, findAll, findAll, findAllIds, findAllIds, findById, findById, findByObjectQuery, findByQuery, findByWhere, findByWhere, findIdsByWhere, findIdsByWhere, getDatabaseMetadata, getDbms, getSessionFactory, isOracle, jdbcUpdate, jdbcUpdate, query, query, queryForDouble, queryForDouble, queryForInt, queryForInt, queryForList, queryForList, queryForList, queryForLong, queryForLong, queryForObject, queryForRowSet, queryForRowSet, queryForString, setSessionFactory
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.logicaldoc.core.PersistentObjectDAO
bulkUpdate, delete, deleteAll, deleteAll, findAll, findAll, findAllIds, findAllIds, findById, findById, findByObjectQuery, findByQuery, findByWhere, findByWhere, findIdsByWhere, findIdsByWhere, getDatabaseMetadata, getDbms, isOracle, jdbcUpdate, jdbcUpdate, query, query, queryForDouble, queryForDouble, queryForInt, queryForInt, queryForList, queryForList, queryForList, queryForLong, queryForLong, queryForObject, queryForRowSet, queryForRowSet, queryForString
-
Method Details
-
findByTemplate
public List<BarcodeTemplate> findByTemplate(Long templateId, Long tenantId) throws com.logicaldoc.core.PersistenceException Description copied from interface:BarcodeTemplateDAO
This method finds all the barcode templates assigned to the same template.- Specified by:
findByTemplate
in interfaceBarcodeTemplateDAO
- Parameters:
templateId
- ID of the template (may be null in case you specify the tenantId)tenantId
- ID of the tenant in which to search (may be null in case you specify templateId)- Returns:
- list of barcode templates
- Throws:
com.logicaldoc.core.PersistenceException
- error querying the database
-
findByName
public BarcodeTemplate findByName(String name, long tenantId) throws com.logicaldoc.core.PersistenceException Description copied from interface:BarcodeTemplateDAO
This method finds the ocr template by it's name(alternate key inside the tenant).- Specified by:
findByName
in interfaceBarcodeTemplateDAO
- Parameters:
name
- the name of the barcode templatetenantId
- ID of the owner tenant- Returns:
- the template
- Throws:
com.logicaldoc.core.PersistenceException
- error querying the database
-
initialize
- Specified by:
initialize
in interfacecom.logicaldoc.core.PersistentObjectDAO<BarcodeTemplate>
- Overrides:
initialize
in classcom.logicaldoc.core.HibernatePersistentObjectDAO<BarcodeTemplate>
-
delete
public void delete(long templateId, int code) throws com.logicaldoc.core.PersistenceException - Specified by:
delete
in interfacecom.logicaldoc.core.PersistentObjectDAO<BarcodeTemplate>
- Overrides:
delete
in classcom.logicaldoc.core.HibernatePersistentObjectDAO<BarcodeTemplate>
- Throws:
com.logicaldoc.core.PersistenceException
-
store
- Specified by:
store
in interfacecom.logicaldoc.core.PersistentObjectDAO<BarcodeTemplate>
- Overrides:
store
in classcom.logicaldoc.core.HibernatePersistentObjectDAO<BarcodeTemplate>
- Throws:
com.logicaldoc.core.PersistenceException
-