Interface MessageTemplateDAO
- All Superinterfaces:
PersistentObjectDAO<MessageTemplate>
- All Known Implementing Classes:
HibernateMessageTemplateDAO
This is a DAO service for MessageTemplate.
- Since:
- 6.5
- Author:
- Marco Meschieri - LogicalDOC
-
Field Summary
Fields inherited from interface com.logicaldoc.core.PersistentObjectDAO
ENTITY
-
Method Summary
Modifier and TypeMethodDescriptionfindByLanguage
(String language, long tenantId) Finds the templates by given languagefindByName
(String name, long tenantId) Finds the templates by given name, you may have the same name but for different languages.findByNameAndLanguage
(String name, String language, long tenantId) Finds the template by the alternate key.findByTypeAndLanguage
(String type, String language, long tenantId) Finds the templates by the type.Methods inherited from interface com.logicaldoc.core.PersistentObjectDAO
bulkUpdate, delete, delete, deleteAll, deleteAll, findAll, findAll, findAllIds, findAllIds, findById, findById, findByObjectQuery, findByQuery, findByWhere, findByWhere, findIdsByWhere, findIdsByWhere, getDatabaseMetadata, getDbms, initialize, isOracle, jdbcUpdate, jdbcUpdate, query, query, queryForDouble, queryForDouble, queryForInt, queryForList, queryForList, queryForList, queryForLong, queryForLong, queryForObject, queryForRowSet, queryForRowSet, queryForString, store
-
Method Details
-
findByLanguage
Finds the templates by given language- Parameters:
language
- the languagetenantId
- identifier of the tenant- Returns:
- collection of templates
-
findByName
Finds the templates by given name, you may have the same name but for different languages.- Parameters:
name
- name of the templatetenantId
- identifier of the tenant- Returns:
- collection of templates
-
findByNameAndLanguage
Finds the template by the alternate key. If the template is not found for the specified language, the 'en' will be used instead.- Parameters:
name
- name of the templatelanguage
- the language, if null 'en' will be used insteadtenantId
- the tenant- Returns:
- The found template or the 'en' if none was found
-
findByTypeAndLanguage
Finds the templates by the type.- Parameters:
type
- type of the templatelanguage
- the languagetenantId
- the tenant- Returns:
- the found templates
-