Package com.randomnoun.common.jexl.sql
Class SqlText
java.lang.Object
com.randomnoun.common.jexl.sql.SqlText
Class to mark a String as generated 'SQL' (as opposed to
a String literal).
As the SqlGenerator traverses nodes in the AST graph, the visit() methods return values which are either POJOs (Integers, Strings, Longs, etc...) which are evaluated from the AST, or SQL text, which is basically an opaque string which is generated from what we've seen so far in the AST; (e.g. "abc > 123 AND def LIKE 'GHI'"). As soon as a POJO is converted into it's SQL form, it is wrappered in this object, so that other visit() nodes don't accidentally try to evaluate it.
- Author:
- knoxg
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionRetrieve the SQL snippet stored in this object.toString()
We supply a .toString() method to make debugging easier