All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.kvisco.xsl.EqualityExpr

com.kvisco.xsl.EqualityExpr

public class EqualityExpr
implements Expr
Represents an EqualityExpr

Author:
Keith Visco (kvisco@ziplink.net)

Variable Index

 o EQUAL
 o GREATER_THAN
 o GT_OR_EQUAL
 o LESS_THAN
 o LT_OR_EQUAL
 o NOT_EQUAL

Constructor Index

 o EqualityExpr(Expr, Expr)
Creates a new EqualityExpr using the default operator
 o EqualityExpr(Expr, Expr, short)
Creates a new EqualityExpr
 o EqualityExpr(Expr, Expr, String)
Creates a new EqualityExpr

Method Index

 o evaluate(Node, ProcessorState)
Evaluates this Expr using the given context Node and ProcessorState
 o evaluate(Node, ProcessorState)
Evaluates this Expr using the given context Node and ProcessorState
 o getExprType()
Returns the type of Expr this Expr represents
 o isRelationalOperator(String)
 o toString()
Returns the String representation of this EqualityExpr

Variables

 o EQUAL
 public static final short EQUAL
 o LESS_THAN
 public static final short LESS_THAN
 o GREATER_THAN
 public static final short GREATER_THAN
 o LT_OR_EQUAL
 public static final short LT_OR_EQUAL
 o GT_OR_EQUAL
 public static final short GT_OR_EQUAL
 o NOT_EQUAL
 public static final short NOT_EQUAL

Constructors

 o EqualityExpr
 public EqualityExpr(Expr leftSideExpr,
                     Expr rightSideExpr)
Creates a new EqualityExpr using the default operator

Parameters:
leftSideExpr - the Expr that is to be evaluated as the left side of this EqualityExpr
rightSideExpr - the Expr that is to be evaluated as the right side of this EqualityExpr
Note: the default operator is EqualityExpr.EQUALS
 o EqualityExpr
 public EqualityExpr(Expr leftSideExpr,
                     Expr rightSideExpr,
                     short compareOp) throws InvalidExprException
Creates a new EqualityExpr

Parameters:
leftSideExpr - the Expr that is to be evaluated as the left side of this EqualityExpr
rightSideExpr - the Expr that is to be evaluated as the right side of this EqualityExpr
compareOp - the comparison operator for this EqualityExpr
Throws: InvalidExprException
when the comparison operator is invalid
 o EqualityExpr
 public EqualityExpr(Expr leftSideExpr,
                     Expr rightSideExpr,
                     String compareOp) throws InvalidExprException
Creates a new EqualityExpr

Parameters:
leftSideExpr - the Expr that is to be evaluated as the left side of this EqualityExpr
rightSideExpr - the Expr that is to be evaluated as the right side of this EqualityExpr
compareOp - the comparison operator for this EqualityExpr
Throws: InvalidExprException
when the comparison operator is invalid

Methods

 o getExprType
 public short getExprType()
Returns the type of Expr this Expr represents

Returns:
the type of Expr this Expr represents
 o evaluate
 public ExprResult evaluate(Node context,
                            ProcessorState ps) throws InvalidExprException
Evaluates this Expr using the given context Node and ProcessorState

Parameters:
context - the current context Node
ps - the ProcessorState that contains the current processing environment
Returns:
the ExprResult
 o isRelationalOperator
 public static boolean isRelationalOperator(String operator)
 o toString
 public String toString()
Returns the String representation of this EqualityExpr

Returns:
the String representation of this EqualityExpr

All Packages  Class Hierarchy  This Package  Previous  Next  Index