|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.google.sitebricks.compiler.Parsing
public class Parsing
Utility tokenizes text into expressions and raw text, and provides other text parsing tools.
| Method Summary | |
|---|---|
static TypeConverter |
getTypeConverter()
|
static int |
indexOfMeta(String template)
|
static boolean |
isExpression(String attribute)
|
static boolean |
isValidURI(String uri)
|
static String |
render(List<Token> tokens,
Map<String,Object> arguments)
Converts the given token stream into a rendered output evaluating each expression against the provided context object which may be a regular Java POJO with getters and setters or a map of string/value pairs. |
static void |
setTypeConverter(TypeConverter converter)
|
static String |
stripExpression(String expr)
|
static String |
stripQuotes(String var)
|
static Map<String,String> |
toBindMap(String expression)
|
static List<Token> |
tokenize(String warpRawText,
EvaluatorCompiler compiler)
|
static boolean |
treatAsXml(String template)
Remember this method is not so much about verifying something is XML as it is verifying that something is a NON-Xml template. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static Map<String,String> toBindMap(String expression)
public static List<Token> tokenize(String warpRawText,
EvaluatorCompiler compiler)
throws ExpressionCompileException
ExpressionCompileExceptionpublic static String stripExpression(String expr)
public static boolean isExpression(String attribute)
public static String stripQuotes(String var)
public static boolean treatAsXml(String template)
template - A fully loaded template as a string.
@Meta annotation.
public static String render(List<Token> tokens,
Map<String,Object> arguments)
public static int indexOfMeta(String template)
public static boolean isValidURI(String uri)
public static TypeConverter getTypeConverter()
@Inject public static void setTypeConverter(TypeConverter converter)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||