BEA Systems, Inc.

WebLogic Server 6.1 API Reference

weblogic.apache.xpath.patterns
Class UnionPattern

java.lang.Object
  |
  +--weblogic.apache.xpath.Expression
        |
        +--weblogic.apache.xpath.patterns.UnionPattern

public class UnionPattern
extends Expression

This class represents a union pattern, which can have multiple individual StepPattern patterns.

Author:
Copyright © 2001 BEA Systems, Inc. All Rights Reserved.
See Also:
Serialized Form

Fields inherited from class weblogic.apache.xpath.Expression
m_slocator
 
Constructor Summary
UnionPattern()
           
 
Method Summary
 boolean canTraverseOutsideSubtree()
          Tell if this expression or it's subexpressions can traverse outside the current subtree.
 XObject execute(XPathContext xctxt)
          Test a node to see if it matches any of the patterns in the union.
 StepPattern[] getPatterns()
          Get the contained step patterns to be tested.
 void setPatterns(StepPattern[] patterns)
          Set the contained step patterns to be tested.
 
Methods inherited from class weblogic.apache.xpath.Expression
assert, error, setSourceLocator, warn
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UnionPattern

public UnionPattern()
Method Detail

canTraverseOutsideSubtree

public boolean canTraverseOutsideSubtree()
Tell if this expression or it's subexpressions can traverse outside the current subtree.

Returns:
true if traversal outside the context node's subtree can occur.
Overrides:
canTraverseOutsideSubtree in class Expression

setPatterns

public void setPatterns(StepPattern[] patterns)
Set the contained step patterns to be tested.

Parameters:
patterns - the contained step patterns to be tested.

getPatterns

public StepPattern[] getPatterns()
Get the contained step patterns to be tested.

Returns:
an array of the contained step patterns to be tested.

execute

public XObject execute(XPathContext xctxt)
                throws javax.xml.transform.TransformerException
Test a node to see if it matches any of the patterns in the union.

Parameters:
xctxt - XPath runtime context.
Returns:
NodeTest.SCORE_NODETEST, NodeTest.SCORE_NONE, NodeTest.SCORE_NSWILD, NodeTest.SCORE_QNAME, or NodeTest.SCORE_OTHER.
Throws:
javax.xml.transform.TransformerException -  
Overrides:
execute in class Expression

Documentation is available at
http://e-docs.bea.com/wls/docs61

WebLogic classes and methods that do not appear in this reference are not public and are not supported.