java.lang.Object
io.jmix.reportsui.screen.report.wizard.template.generators.HtmlGenerator
All Implemented Interfaces:
Generator

@Component("report_HtmlGenerator") public class HtmlGenerator extends Object implements Generator
  • Field Details

    • HTML_TEMPLATE_NAME

      protected static final String HTML_TEMPLATE_NAME
      See Also:
    • HTML_TEMPLATE_PLACEHOLDER_TITLE

      protected static final String HTML_TEMPLATE_PLACEHOLDER_TITLE
      See Also:
    • HTML_TEMPLATE_PLACEHOLDER_STYLES

      protected static final String HTML_TEMPLATE_PLACEHOLDER_STYLES
      See Also:
    • HTML_TEMPLATE_PLACEHOLDER_BODY

      protected static final String HTML_TEMPLATE_PLACEHOLDER_BODY
      See Also:
    • reportTemplatePlaceholder

      @Autowired protected ReportTemplatePlaceholder reportTemplatePlaceholder
    • messages

      @Autowired protected Messages messages
    • freeMarkerConfiguration

      protected static volatile freemarker.template.Configuration freeMarkerConfiguration
  • Constructor Details

    • HtmlGenerator

      public HtmlGenerator()
  • Method Details

    • generate

      public byte[] generate(ReportData reportData) throws freemarker.template.TemplateException, IOException
      Specified by:
      generate in interface Generator
      Throws:
      freemarker.template.TemplateException
      IOException
    • putTitleHtml

      protected void putTitleHtml(String title, Map<String,String> templateParameters)
    • putStylesHtml

      protected void putStylesHtml(Map<String,String> templateParameters)
    • putBodyHtml

      protected void putBodyHtml(List<ReportRegion> reportRegions, Map<String,String> templateParameters)
    • appendFreeMarkerSettings

      protected void appendFreeMarkerSettings(StringBuilder templateBody)
    • appendHtmlFreeMarkerAssignments

      protected void appendHtmlFreeMarkerAssignments(StringBuilder stringBuilder, String bandName)
    • getFreemarkerConfiguration

      protected freemarker.template.Configuration getFreemarkerConfiguration()
    • getReportTemplateHtmlFreeMarkerTemplate

      protected String getReportTemplateHtmlFreeMarkerTemplate()