format
public static java.lang.String format(java.lang.String content,
java.util.Map<java.lang.String,java.lang.String> predefinedMacros)
throws BadSyntax
A simple formatting wrapper that formats a string using macros that are provided in a Map. The Map is
String String map and these macros cannot have arguments. This is a simple templating implementation
using Jamal as a template engine.
- Parameters:
content
- the text that uses the macros
predefinedMacros
- the Map that contains the predefined macros
- Returns:
- the formatted string
- Throws:
BadSyntax
- in case the string cannot be formatted using the provided macros