Class HibernateMessageTemplateDAO

    • Constructor Detail

      • HibernateMessageTemplateDAO

        public HibernateMessageTemplateDAO()
    • Method Detail

      • findByNameAndLanguage

        public MessageTemplate findByNameAndLanguage​(String name,
                                                     String language,
                                                     long tenantId)
        Description copied from interface: MessageTemplateDAO
        Finds the template by the alternate key. If the template is not found for the specified language, the 'en' will be used instead.
        Specified by:
        findByNameAndLanguage in interface MessageTemplateDAO
        Parameters:
        name - name of the template
        language - the language, if null 'en' will be used instead
        tenantId - the tenant
        Returns:
        The found template or the 'en' if none was found
      • findByName

        public List<MessageTemplate> findByName​(String name,
                                                long tenantId)
        Description copied from interface: MessageTemplateDAO
        Finds the templates by given name, you may have the same name but for different languages.
        Specified by:
        findByName in interface MessageTemplateDAO
        Parameters:
        name - name of the template
        tenantId - identifier of the tenant
        Returns:
        collection of templates