Templates gives you the flexibility to separate the commonly occurring data as static content and merge with variables to produce desired output during runtime.
Templates can be effectively used for
- Creating elastic search queries
- Inbuilt distributed database queries
- External RDBMS SQL queries
Context Variable: template
//Define a template. See http://jtwig.org public void define(String name, String code); //Merge the supplied parameters with the template public String merge(String name, Map<String, Object> params);
Updated over 1 year ago