The Query Tree is generated by the Parser from the Token Tree. The Syntax of the Query is already checked at this point and several operations have been eliminated for the Query to work. The Query Tree has an Object Context given by the Class Index for that object (using the abstract)
|Leaf Node:||Predicate Tree.||P|
|NonLeaf Nodes:||Association Query||A|
|Except / Difference||E|
|Distinct Flag||All NonLeaf Nodes|
|Pointer to Children||All NonLeaf Nodes|
|Predicate String||A, B|
|Predicate Tree Object||P|
A Distinct Flag on every NonLeaf Node tells us whether a Bag or a Set should be the result of the operation.
The Predicate String is only needed for the Bag and Association Queries because they operate on an incoming bag.
The Association Name defines the Member Chain for the Association Query.
The Predicate Tree and Intersection objects are explained below.
For the details of the class structure and the format of the input/output stream consult the appendix.
The binary nodes
The unary nodes