Interface HelperPlugin<T>

Type Parameters:
T - Context type for helper
All Superinterfaces:
Plugin
All Known Implementing Classes:
ContainsHelper, DisallowPropertyHelper, EachIfEqualsHelper, EachIfHelper, EnsurePropertiesHelper, IfEqualsHelper, IfNotEqualsHelper, RegexQuoteHelper

public interface HelperPlugin<T> extends Plugin
Plugin that allows to register custom Handlebars Helper extensions that can be used in all templates. The name of the plugin is used as helper name for registering in Handlebars.
  • Method Summary

    Modifier and Type
    Method
    Description
    apply(T context, com.github.jknack.handlebars.Options options, HelperContext pluginContext)
    Apply the helper to the context.

    Methods inherited from interface io.wcm.devops.conga.generator.spi.Plugin

    getName
  • Method Details

    • apply

      Object apply(T context, com.github.jknack.handlebars.Options options, HelperContext pluginContext) throws IOException
      Apply the helper to the context.
      Parameters:
      context - The context object.
      options - The options object.
      pluginContext - Plugin context
      Returns:
      A string result.
      Throws:
      IOException - If a template cannot be loaded.