org.oXML.xpath.step
Class MathExpression

java.lang.Object
  extended byorg.oXML.xpath.step.MathExpression
All Implemented Interfaces:
Expression

public class MathExpression
extends java.lang.Object
implements Expression

tbd - how compare a nodeset and boolean ??? eg test="/foo/bar < true" ??? or even - how compare two booleans? or two strings - lexicographically?? xalan gave me false on 'true <= false', 'true > false' and '"abc" <= "abc"'.


Field Summary
static int DIVISION
           
static int MINUS
           
static int MODULO
           
static int MULTIPLICATION
           
static int PLUS
           
 
Fields inherited from interface org.oXML.xpath.Expression
OUTPUT_NS
 
Constructor Summary
MathExpression(Expression lhs, Expression rhs, int operation)
           
 
Method Summary
 void bind(Resolver ctxt)
           
 Node evaluate(RuntimeContext ctxt)
           
 java.lang.String getOperation()
           
 int operation()
           
 java.lang.String toString()
           
 void write(org.xml.sax.ContentHandler handler)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

PLUS

public static final int PLUS
See Also:
Constant Field Values

MINUS

public static final int MINUS
See Also:
Constant Field Values

DIVISION

public static final int DIVISION
See Also:
Constant Field Values

MODULO

public static final int MODULO
See Also:
Constant Field Values

MULTIPLICATION

public static final int MULTIPLICATION
See Also:
Constant Field Values
Constructor Detail

MathExpression

public MathExpression(Expression lhs,
                      Expression rhs,
                      int operation)
Method Detail

bind

public void bind(Resolver ctxt)
          throws ObjectBoxException
Specified by:
bind in interface Expression
Throws:
ObjectBoxException

operation

public int operation()

getOperation

public java.lang.String getOperation()

evaluate

public Node evaluate(RuntimeContext ctxt)
              throws ObjectBoxException
Specified by:
evaluate in interface Expression
Throws:
ObjectBoxException

toString

public java.lang.String toString()

write

public void write(org.xml.sax.ContentHandler handler)
           throws org.xml.sax.SAXException
Specified by:
write in interface Expression
Throws:
org.xml.sax.SAXException