Class VariableNode

  • All Implemented Interfaces:
    ExpressionNode

    public class VariableNode
    extends java.lang.Object
    implements ExpressionNode
    Author:
    Simon Thoresen Hult
    • Constructor Summary

      Constructors 
      Constructor Description
      VariableNode​(java.lang.String value)  
    • Constructor Detail

      • VariableNode

        public VariableNode​(java.lang.String value)
    • Method Detail

      • getValue

        public java.lang.Object getValue()
      • setValue

        public VariableNode setValue​(java.lang.String value)
      • evaluate

        public java.lang.Object evaluate​(Context context)
        Description copied from interface: ExpressionNode
        Evaluate the content of this node based on document object, and return that value.
        Specified by:
        evaluate in interface ExpressionNode
        Parameters:
        context - The document to evaluate over.
        Returns:
        The value of this.
      • accept

        public void accept​(Visitor visitor)
        Description copied from interface: ExpressionNode
        Perform visitation of this node.
        Specified by:
        accept in interface ExpressionNode
        Parameters:
        visitor - The visitor that wishes to visit the node.
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • getOrdering

        public OrderingSpecification getOrdering​(int order)
        Description copied from interface: ExpressionNode
        If this document selection implies a specific ordering (using the orderdoc scheme), return that specification.
        Specified by:
        getOrdering in interface ExpressionNode
        Parameters:
        order - The order in which we are looking to traverse the ordering (ASCENDING or DESCENDING)