Class TypeAwareSQLTreeProcessor
java.lang.Object
org.apache.cayenne.access.sqlbuilder.sqltree.SimpleNodeTreeVisitor
org.apache.cayenne.access.translator.select.TypeAwareSQLTreeProcessor
- All Implemented Interfaces:
NodeTreeVisitor
,SQLTreeProcessor
- Direct Known Subclasses:
MySQLTreeProcessor
,PostgreSQLTreeProcessor
- Since:
- 4.2
-
Field Summary
Modifier and TypeFieldDescriptionprotected final Map
<String, ChildProcessor<ColumnNode>> protected final Map
<NodeType, ChildProcessor<Node>> protected final Map
<String, ChildProcessor<ValueNode>> protected static final Class
<?> protected static final String
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiondefaultProcess
(Node parent, Node child, int index) protected DbAttribute
getColumnAttribute
(ColumnNode node) protected ChildProcessor
<ColumnNode> protected static Optional
<ObjAttribute> getObjAttributeFor
(DbAttribute dbAttribute) protected DbAttribute
getValueAttribute
(ValueNode node) protected ChildProcessor
<ValueNode> getValueProcessor
(DbAttribute attr) boolean
onChildNodeStart
(Node parent, Node child, int index, boolean hasMore) protected void
registerColumnProcessor
(Class<?> columnType, ChildProcessor childProcessor) protected void
registerProcessor
(NodeType nodeType, ChildProcessor childProcessor) protected void
registerValueProcessor
(Class<?> columnType, ChildProcessor childProcessor) protected static void
replaceChild
(Node parent, int index, Node newChild) protected static Node
wrapInFunction
(Node node, String function) Methods inherited from class org.apache.cayenne.access.sqlbuilder.sqltree.SimpleNodeTreeVisitor
onChildNodeEnd, onNodeEnd, onNodeStart
-
Field Details
-
DEFAULT_TYPE
-
DEFAULT_TYPE_NAME
-
byColumnTypeProcessors
-
byValueTypeProcessors
-
byNodeTypeProcessors
-
-
Constructor Details
-
TypeAwareSQLTreeProcessor
public TypeAwareSQLTreeProcessor()
-
-
Method Details
-
process
- Specified by:
process
in interfaceSQLTreeProcessor
-
registerProcessor
-
registerColumnProcessor
-
registerValueProcessor
-
defaultProcess
-
onChildNodeStart
- Specified by:
onChildNodeStart
in interfaceNodeTreeVisitor
- Overrides:
onChildNodeStart
in classSimpleNodeTreeVisitor
- Parameters:
parent
- nodechild
- nodeindex
- of this child in parenthasMore
- true if more children after this child- Returns:
- false if visitor should stop
-
getColumnAttribute
-
getColumnProcessor
-
getValueAttribute
-
getValueProcessor
-
replaceChild
-
wrapInFunction
-
getObjAttributeFor
-