Class FreemarkerTemplateProcessor

    • Constructor Detail

      • FreemarkerTemplateProcessor

        public FreemarkerTemplateProcessor()
    • Method Detail

      • processTemplate

        protected String processTemplate​(freemarker.template.Template templateImplementation,
                                         Map<String,​Object> data)
        Description copied from class: BaseTemplateProcessor
        Run a template implementation for specific data set.
        Specified by:
        processTemplate in class BaseTemplateProcessor<freemarker.template.Template>
        Parameters:
        templateImplementation - the template to process
        data - the data which should be passed to the template
        Returns:
        the template output
      • createTemplateImplementation

        protected freemarker.template.Template createTemplateImplementation​(Template template,
                                                                            String source)
        Description copied from class: BaseTemplateProcessor
        To be implemented by the subclass. Based on the template from the DB and the complete template source, create a language specific template implementation instance.
        Specified by:
        createTemplateImplementation in class BaseTemplateProcessor<freemarker.template.Template>
        Parameters:
        template - the template object from the DB
        source - the complete source (after resolving and including all dependencies)
        Returns:
        the template implementation
      • getTemplateLanguage

        public String getTemplateLanguage()
        Returns:
        the template language supported by this template processor