Package org.nuxeo.template.fm
Class FreeMarkerVariableExtractor
- java.lang.Object
-
- org.nuxeo.template.fm.FreeMarkerVariableExtractor
-
public class FreeMarkerVariableExtractor extends Object
Helper class used to extract variable names from a FreeMarker template. This is used to initialize theTemplateInput
parameters. Extraction is for now simple and system may not detect all the cases, but user is able to add parameters from the UI.- Author:
- Tiry ([email protected])
-
-
Field Summary
Fields Modifier and Type Field Description protected static Pattern[]
assignMatchers
protected static Pattern[]
directiveMatchers
protected static String[]
freeMarkerVariableSuffix
protected static List<String>
reservedContextKeywords
protected static Pattern
simpleVariableMatcher
protected static String[]
spliters
-
Constructor Summary
Constructors Constructor Description FreeMarkerVariableExtractor()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description protected static String
extractVariableName(String match)
static List<String>
extractVariables(String content)
protected static List<String>
getreservedContextKeywords()
static void
resetReservedContextKeywords()
-
-
-
Field Detail
-
simpleVariableMatcher
protected static final Pattern simpleVariableMatcher
-
spliters
protected static final String[] spliters
-
directiveMatchers
protected static final Pattern[] directiveMatchers
-
assignMatchers
protected static final Pattern[] assignMatchers
-
freeMarkerVariableSuffix
protected static final String[] freeMarkerVariableSuffix
-
-