Class BranchNode

    • Method Detail

      • isLeaf

        public final boolean isLeaf()
        Description copied from interface: ExprNode
        Tests to see if this node is a leaf or branch node.
        Returns:
        false all the time.
        See Also:
        ExprNode.isLeaf()
      • addNode

        public void addNode​(ExprNode node)
        Adds a child node to this branch node node
        Parameters:
        node - the child expression to add to this branch node
      • addNodeToHead

        public void addNodeToHead​(ExprNode node)
        Adds a child node to this branch node at the head rather than the tail.
        Parameters:
        node - the child expression to add to this branch node
      • getChildren

        public List<ExprNodegetChildren()
        Gets the children below this BranchNode. We purposefully do not clone the array list so that backends can sort the order of children using their own search optimization algorithms. We want backends and other parts of the system to be able to induce side effects on the tree structure.
        Returns:
        the list of child nodes under this branch node.
      • setChildren

        public void setChildren​(List<ExprNode> list)
        Sets the list of children under this node.
        Parameters:
        list - the list of children to set.
      • getFirstChild

        public ExprNode getFirstChild()
        Convenience method that gets the first child in the children array. Its very useful for NOT nodes since they only have one child by avoiding code that looks like: ( ExprNode ) m_children.get( 0 )
        Returns:
        the first child
      • isSchemaAware

        public boolean isSchemaAware()
        Tells if this Node is Schema aware.
        Returns:
        true if the Node is SchemaAware