All Packages Class Hierarchy This Package Previous Next Index
Class com.kvisco.xsl.FilterBase
com.kvisco.xsl.FilterBase
- public abstract class FilterBase
- implements MatchExpr
- Author:
- Keith Visco (kvisco@ziplink.net)
-
ANCESTOR_OP
-
-
NO_OP
-
-
PARENT_OP
-
-
FilterBase()
- Creates a new FilterBase
-
addPredicate(Expr)
- Adds the given Expression to this FilterBase's predicate
List.
-
evaluate(Node, ProcessorState)
- Evaluates this FilterBase using the given context node, and
ProcessorState
-
evaluatePredicates(NodeSet, ProcessorState)
- Evaluates the PredicateExpr of this FilterBase against the given Node.
-
getAncestryOp()
-
-
getDefaultPriority()
- Determines the priority of a PatternExpr as follows:
- From the 19990421 XSL Working Draft -
+ If the Pattern has the form of a QName optionally preceded by
the
-
getPredicates()
- Returns the List of predicates of this FilterBase
-
matches(Node, Node, ProcessorState)
- Determines if the given node is matched by this MatchExpr with
respect to the given context node.
-
matches(Node, Node, ProcessorState)
- Determines if the given node is matched by this MatchExpr with
respect to the given context node.
-
removePredicate(Expr)
- Removes the given predicate from this FilterBase
-
setAncestryOp(int)
- Sets the AncestryOp for this FilterBase
-
toString()
- Returns the String representation of this FilterBase
NO_OP
public static final int NO_OP
ANCESTOR_OP
public static final int ANCESTOR_OP
PARENT_OP
public static final int PARENT_OP
FilterBase
public FilterBase()
- Creates a new FilterBase
addPredicate
public void addPredicate(Expr expr)
- Adds the given Expression to this FilterBase's predicate
List.
- Parameters:
- expr - the Expr to add to the predicate list
getDefaultPriority
public abstract int getDefaultPriority()
- Determines the priority of a PatternExpr as follows:
- From the 19990421 XSL Working Draft -
+ If the Pattern has the form of a QName optionally preceded by
the @ character, then the priority is 0.
+ Otherwise if the pattern consists of just a NodeTest then the
priority is -1
+ Otherwise the priority is 1
- Returns:
- the priority for this PatternExpr
evaluate
public abstract NodeSet evaluate(Node context,
ProcessorState ps) throws InvalidExprException
- Evaluates this FilterBase using the given context node, and
ProcessorState
- Parameters:
- context - the context node for evaluation
- ps - the current ProcessorState
evaluatePredicates
public void evaluatePredicates(NodeSet nodes,
ProcessorState ps) throws InvalidExprException
- Evaluates the PredicateExpr of this FilterBase against the given Node.
- Parameters:
- nodes - the current NodeSet
- ps - the current ProcessorState
getAncestryOp
public int getAncestryOp()
getPredicates
public List getPredicates()
- Returns the List of predicates of this FilterBase
- Returns:
- the List of predicates of this FilterBase
matches
public abstract boolean matches(Node node,
Node context,
ProcessorState ps) throws InvalidExprException
- Determines if the given node is matched by this MatchExpr with
respect to the given context node.
- Parameters:
- node - the node to determine a match for
- context - the Node which represents the current context
- ps - the current ProcessorState
- Returns:
- true if the given node is matched by this MatchExpr
removePredicate
public void removePredicate(Expr expr)
- Removes the given predicate from this FilterBase
- Parameters:
- expr - the Expr to remove from the predicate list
setAncestryOp
public void setAncestryOp(int ancestryOp)
- Sets the AncestryOp for this FilterBase
- Parameters:
- ancestryOp - the ancestry operator to use when
evaluating expressions
toString
public String toString()
- Returns the String representation of this FilterBase
- Returns:
- the String representation of this FilterBase
All Packages Class Hierarchy This Package Previous Next Index