Class SafeFunctions
java.lang.Object
org.apache.juneau.commons.template.SafeFunctions
The default function allowlist of a
TemplateResolver.
Pure, bounded string and collection helpers, the structure functions and the operators. Deliberately left out:
- Functions that read arbitrary data (
jsonPath ,get ,extract ,keys ,values ). - Regex functions (
match ,replaceRegex ), which can backtrack catastrophically on author-chosen patterns. - Non-deterministic functions (
rand* ,uuid ,now ) and date parsing. - Functions that can allocate large results from small input (
repeat ) or that reach the platform (switch , the encoding functions).
TemplateResolver.Builder.allowFunctions(String...) replaces this list.-
Method Summary
-
Method Details
-
patterns
Returns the default allowlist patterns.- Returns:
- An unmodifiable list of glob patterns, as accepted by
VarResolver.Builder.allowFunctions(String...).
-