Search in sources :

Example 1 with HandlebarsHelper

use of org.codice.ddf.registry.rest.endpoint.HandlebarsHelper in project ddf by codice.

the class RegistryReportBuilder method setup.

public void setup() {
    templateLoader = new ClassPathTemplateLoader();
    templateLoader.setPrefix("/templates");
    templateLoader.setSuffix(".hbt");
    handlebars = new Handlebars(templateLoader);
    handlebars.registerHelpers(new HandlebarsHelper());
    handlebars.registerHelpers(StringHelpers.class);
}
Also used : Handlebars(com.github.jknack.handlebars.Handlebars) ClassPathTemplateLoader(com.github.jknack.handlebars.io.ClassPathTemplateLoader) HandlebarsHelper(org.codice.ddf.registry.rest.endpoint.HandlebarsHelper)

Aggregations

Handlebars (com.github.jknack.handlebars.Handlebars)1 ClassPathTemplateLoader (com.github.jknack.handlebars.io.ClassPathTemplateLoader)1 HandlebarsHelper (org.codice.ddf.registry.rest.endpoint.HandlebarsHelper)1