Package gorsat
Class FreemarkerQueryUtilities
- java.lang.Object
-
- gorsat.FreemarkerQueryUtilities
-
public class FreemarkerQueryUtilities extends java.lang.ObjectHelper functions to parse and create reports with the freemarker parsing engine.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.util.Optional<java.lang.String>requestQuery(java.lang.String resource, org.gorpipe.gor.model.FileReader fileResolver, org.gorpipe.gor.model.QueryEvaluator queryEval, java.lang.String reportName, java.util.Map<java.lang.String,java.lang.String> parameterMap, java.lang.String cacheDir)Returns a gor query from the input resource file.
-
-
-
Method Detail
-
requestQuery
public static java.util.Optional<java.lang.String> requestQuery(java.lang.String resource, org.gorpipe.gor.model.FileReader fileResolver, org.gorpipe.gor.model.QueryEvaluator queryEval, java.lang.String reportName, java.util.Map<java.lang.String,java.lang.String> parameterMap, java.lang.String cacheDir) throws java.io.IOException, freemarker.template.TemplateExceptionReturns a gor query from the input resource file. The gor query is fully resolved and freemarker placeholders are fully replaced by the input parameterMap.- Parameters:
resource- Path to freemarker yml filefileResolver- FileReader instance used for the current executionqueryEval- Query evaluator based on the current session, for using gor queries within freemarker syntaxreportName- Name of the report being generatedparameterMap- Map og parameters and their corresponding values.cacheDir- Current cache directory- Returns:
- Fully resolved gor query from the input yml file
- Throws:
java.io.IOException- Yml file not foundfreemarker.template.TemplateException- Internal freemarker error
-
-