Xalan-C++ API Documentation

The Xalan C++ XSLT Processor Version 1.4

Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

XPath.hpp

Go to the documentation of this file.
00001 /*
00002  * The Apache Software License, Version 1.1
00003  *
00004  *
00005  * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights 
00006  * reserved.
00007  *
00008  * Redistribution and use in source and binary forms, with or without
00009  * modification, are permitted provided that the following conditions
00010  * are met:
00011  *
00012  * 1. Redistributions of source code must retain the above copyright
00013  *    notice, this list of conditions and the following disclaimer. 
00014  *
00015  * 2. Redistributions in binary form must reproduce the above copyright
00016  *    notice, this list of conditions and the following disclaimer in
00017  *    the documentation and/or other materials provided with the
00018  *    distribution.
00019  *
00020  * 3. The end-user documentation included with the redistribution,
00021  *    if any, must include the following acknowledgment:  
00022  *       "This product includes software developed by the
00023  *        Apache Software Foundation (http://www.apache.org/)."
00024  *    Alternately, this acknowledgment may appear in the software itself,
00025  *    if and wherever such third-party acknowledgments normally appear.
00026  *
00027  * 4. The names "Xalan" and "Apache Software Foundation" must
00028  *    not be used to endorse or promote products derived from this
00029  *    software without prior written permission. For written 
00030  *    permission, please contact apache@apache.org.
00031  *
00032  * 5. Products derived from this software may not be called "Apache",
00033  *    nor may "Apache" appear in their name, without prior written
00034  *    permission of the Apache Software Foundation.
00035  *
00036  * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
00037  * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
00038  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
00039  * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
00040  * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
00041  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
00042  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
00043  * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
00044  * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
00045  * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
00046  * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
00047  * SUCH DAMAGE.
00048  * ====================================================================
00049  *
00050  * This software consists of voluntary contributions made by many
00051  * individuals on behalf of the Apache Software Foundation and was
00052  * originally based on software copyright (c) 1999, International
00053  * Business Machines, Inc., http://www.ibm.com.  For more
00054  * information on the Apache Software Foundation, please see
00055  * <http://www.apache.org/>.
00056  */
00057 #if !defined(XPATH_HEADER_GUARD_1357924680)
00058 #define XPATH_HEADER_GUARD_1357924680
00059 
00060 
00061 
00062 // Base header file.  Must be first.
00063 #include <XPath/XPathDefinitions.hpp>
00064 
00065 
00066 
00067 #include <XalanDOM/XalanDOMString.hpp>
00068 
00069 
00070 
00071 #include <PlatformSupport/DoubleSupport.hpp>
00072 
00073 
00074 
00075 // Base class header files...
00076 #include <XPath/XPathExecutionContext.hpp>
00077 
00078 
00079 
00080 #include <XPath/XPathExpression.hpp>
00081 #include <XPath/Function.hpp>
00082 #include <XPath/XPathFunctionTable.hpp>
00083 
00084 
00085 
00086 class Locator;
00087 class PrefixResolver;
00088 class XObject;
00089 class XalanNode;
00090 
00091 
00092 
00093 class XALAN_XPATH_EXPORT XPath
00094 {
00095 public:
00096 
00097     static const XalanDOMChar   PSEUDONAME_ANY[];
00098     static const XalanDOMChar   PSEUDONAME_ROOT[];
00099     static const XalanDOMChar   PSEUDONAME_TEXT[];
00100     static const XalanDOMChar   PSEUDONAME_COMMENT[];
00101     static const XalanDOMChar   PSEUDONAME_PI[];
00102     static const XalanDOMChar   PSEUDONAME_OTHER[];
00103     static const XalanDOMChar   PSEUDONAME_NODE[];
00104 
00105     enum eMatchScore
00106     {
00107         eMatchScoreNone,
00108         eMatchScoreNodeTest,
00109         eMatchScoreNSWild,
00110         eMatchScoreQName,
00111         eMatchScoreOther
00112     };
00113 
00114     class TargetData
00115     {
00116     public:
00117 
00118         enum eTargetType { eAttribute, eElement, eAny, eOther };
00119 
00120         TargetData() :
00121             m_string(0),
00122             m_priority(eMatchScoreNone),
00123             m_targetType(eOther)
00124         {
00125         }
00126 
00127         TargetData(
00128                 const XalanDOMChar*     theString,
00129                 eMatchScore             thePriority,
00130                 eTargetType             theTargetType) :
00131             m_string(theString),
00132             m_priority(thePriority),
00133             m_targetType(theTargetType)
00134         {
00135         }
00136 
00137         const XalanDOMChar*
00138         getString() const
00139         {
00140             return m_string;
00141         }
00142 
00143         eMatchScore
00144         getDefaultPriority() const
00145         {
00146             return m_priority;
00147         }
00148 
00149         eTargetType
00150         getTargetType() const
00151         {
00152             return m_targetType;
00153         }
00154 
00155     private:
00156 
00157         const XalanDOMChar*     m_string;
00158 
00159         eMatchScore             m_priority;
00160 
00161         eTargetType             m_targetType;
00162     };
00163 
00164 #if defined(XALAN_NO_NAMESPACES)
00165     typedef vector<TargetData>      TargetDataVectorType;
00166 #else
00167     typedef std::vector<TargetData> TargetDataVectorType;
00168 #endif
00169 
00170 
00174     static void
00175     initialize();
00176 
00180     static void
00181     terminate();
00182 
00188     explicit
00189     XPath(const Locator*    theLocator = 0);
00190 
00191     virtual
00192     ~XPath();
00193 
00197     void
00198     shrink();
00199 
00208     const XObjectPtr
00209     execute(
00210             XalanNode*              context,
00211             const PrefixResolver&   prefixResolver,
00212             XPathExecutionContext&  executionContext) const;
00213 
00223     const XObjectPtr
00224     execute(
00225             XalanNode*              context,
00226             const PrefixResolver&   prefixResolver,
00227             const NodeRefListBase&  contextNodeList,
00228             XPathExecutionContext&  executionContext) const
00229     {
00230         // Set and restore the context node list...
00231         XPathExecutionContext::ContextNodeListSetAndRestore     theSetAndRestore(
00232                                         executionContext,
00233                                         contextNodeList);   
00234 
00235         return execute(context, prefixResolver, executionContext);
00236     }
00237 
00246     const XObjectPtr
00247     execute(XPathExecutionContext&  executionContext) const
00248     {
00249         assert(executionContext.getPrefixResolver() != 0);
00250 
00251         return executeMore(executionContext.getCurrentNode(), 0, executionContext);
00252     }
00253 
00262     const XObjectPtr
00263     executeMore(
00264             XalanNode*              context,
00265             int                     opPos,
00266             XPathExecutionContext&  executionContext) const;
00267 
00276     const XObjectPtr
00277     locationPath(
00278             XalanNode*              context,
00279             int                     opPos,
00280             XPathExecutionContext&  executionContext) const;
00281 
00287     XPathExpression&
00288     getExpression()
00289     {
00290         return m_expression;
00291     }
00292 
00298     const XPathExpression&
00299     getExpression() const
00300     {
00301         return m_expression;
00302     }
00303 
00304     static double
00305     getMatchScoreValue(eMatchScore  score)
00306     {
00307         switch(score)
00308         {
00309         case eMatchScoreNone:
00310             return DoubleSupport::getNegativeInfinity();
00311             break;
00312 
00313         case eMatchScoreNodeTest:
00314             return -0.5;
00315             break;
00316 
00317         case eMatchScoreNSWild:
00318             return -0.25;
00319             break;
00320 
00321         case eMatchScoreOther:
00322             return 0.5;
00323             break;
00324 
00325         case eMatchScoreQName:
00326             return 0.0;
00327             break;
00328         };
00329 
00330         assert(false);
00331         return 0.0;
00332     }
00333 
00341     eMatchScore
00342     getMatchScore(
00343             XalanNode*              node,
00344             XPathExecutionContext&  executionContext) const;
00345 
00354     eMatchScore
00355     getMatchScore(
00356             XalanNode*              node,
00357             const PrefixResolver&   resolver,
00358             XPathExecutionContext&  executionContext) const;
00359 
00368     const XObjectPtr
00369     predicate(
00370             XalanNode*              context,
00371             int                     opPos,
00372             XPathExecutionContext&  executionContext) const
00373     {
00374         return executeMore(context, opPos + 2, executionContext);
00375     }
00376 
00382     void
00383     getTargetData(TargetDataVectorType&     targetData) const;
00384 
00391     static void
00392     installFunction(
00393             const XalanDOMString&   funcName,
00394             const Function&         func);
00395 
00402     static bool
00403     uninstallFunction(const XalanDOMString&     funcName);
00404 
00411     static bool
00412     isInstalledFunction(const XalanDOMString&   theFunctionName)
00413     {
00414         return s_functions.isInstalledFunction(theFunctionName);
00415     }
00416 
00417     typedef XPathFunctionTable  FunctionTableType;
00418 
00424     static const FunctionTableType&
00425     getFunctionTable()
00426     {
00427         return s_functions;
00428     }
00429 
00430 #if defined(XALAN_NO_MEMBER_TEMPLATES)
00431     typedef XPathFunctionTable::InstalledFunctionNameVectorType
00432                     InstalledFunctionNameVectorType;
00433 
00439     static void
00440     getInstalledFunctionNames(InstalledFunctionNameVectorType&  theVector)
00441     {
00442         s_functions.getInstalledFunctionNames(theVector);
00443     }
00444 #else
00450     template<class OutputIteratorType>
00451     static void
00452     getInstalledFunctionNames(OutputIteratorType    theIterator)
00453     {
00454         s_functions.getInstalledFunctionNames(theIterator);
00455     }
00456 #endif
00457 
00458     static void
00459     destroyTable()
00460     {
00461         s_functions.DestroyTable();
00462     }
00463 
00464     bool
00465     getInStylesheet() const
00466     {
00467         return m_inStylesheet;
00468     }
00469 
00470     void
00471     setInStylesheet(bool    fValue)
00472     {
00473         m_inStylesheet = fValue;
00474     }
00475 
00476     const Locator*
00477     getLocator() const
00478     {
00479         return m_locator;
00480     }
00481 
00482     void
00483     setLocator(const Locator*   theLocator)
00484     {
00485         m_locator = theLocator;
00486     }
00487 
00488 protected:
00489 
00493     XLocator*
00494     createXLocatorHandler() const;
00495 
00502     const XObjectPtr
00503     matchPattern(
00504             XalanNode*              context,
00505             int                     opPos,
00506             XPathExecutionContext&  executionContext) const;
00507 
00508 protected:
00509 
00516     void
00517     doGetMatchScore(
00518             XalanNode*              context,
00519             XPathExecutionContext&  executionContext,
00520             eMatchScore&            score) const;
00521 
00528     const XObjectPtr
00529     Or(
00530             XalanNode*              context,
00531             int                     opPos,
00532             XPathExecutionContext&  executionContext) const;
00533 
00540     const XObjectPtr
00541     And(
00542             XalanNode*              context,
00543             int                     opPos,
00544             XPathExecutionContext&  executionContext) const;
00545 
00552     const XObjectPtr
00553     notequals(
00554             XalanNode*              context,
00555             int                     opPos,
00556             XPathExecutionContext&  executionContext) const;
00557 
00564     const XObjectPtr
00565     equals(
00566             XalanNode*              context,
00567             int                     opPos,
00568             XPathExecutionContext&  executionContext) const;
00569 
00576     const XObjectPtr
00577     lte(
00578             XalanNode*              context,
00579             int                     opPos,
00580             XPathExecutionContext&  executionContext) const;
00581 
00588     const XObjectPtr
00589     lt(
00590             XalanNode*              context,
00591             int                     opPos,
00592             XPathExecutionContext&  executionContext) const;
00593 
00600     const XObjectPtr
00601     gte(
00602             XalanNode*              context,
00603             int                     opPos,
00604             XPathExecutionContext&  executionContext) const;
00605 
00612     const XObjectPtr
00613     gt(
00614             XalanNode*              context,
00615             int                     opPos,
00616             XPathExecutionContext&  executionContext) const;
00617 
00624     const XObjectPtr
00625     plus(
00626             XalanNode*              context,
00627             int                     opPos,
00628             XPathExecutionContext&  executionContext) const;
00629 
00636     const XObjectPtr
00637     minus(
00638             XalanNode*              context,
00639             int                     opPos,
00640             XPathExecutionContext&  executionContext) const;
00641 
00648     const XObjectPtr
00649     mult(
00650             XalanNode*              context,
00651             int                     opPos,
00652             XPathExecutionContext&  executionContext) const;
00653 
00660     const XObjectPtr
00661     div(
00662             XalanNode*              context,
00663             int                     opPos,
00664             XPathExecutionContext&  executionContext) const;
00665 
00672     const XObjectPtr
00673     mod(
00674             XalanNode*              context,
00675             int                     opPos,
00676             XPathExecutionContext&  executionContext) const;
00677 
00684     const XObjectPtr
00685     neg(
00686             XalanNode*              context,
00687             int                     opPos,
00688             XPathExecutionContext&  executionContext) const;
00689 
00696     const XObjectPtr
00697     string(
00698             XalanNode*              context,
00699             int                     opPos,
00700             XPathExecutionContext&  executionContext) const;
00701 
00708     const XObjectPtr
00709     boolean(
00710             XalanNode*              context,
00711             int                     opPos,
00712             XPathExecutionContext&  executionContext) const;
00713  
00720     const XObjectPtr
00721     Union(
00722             XalanNode*              context,
00723             int                     opPos,
00724             XPathExecutionContext&  executionContext) const;
00725 
00732     const XObjectPtr
00733     literal(
00734             XalanNode*              context,
00735             int                     opPos,
00736             XPathExecutionContext&  executionContext) const;
00737   
00744     const XObjectPtr
00745     variable(
00746             XalanNode*              context,
00747             int                     opPos,
00748             XPathExecutionContext&  executionContext) const;
00749 
00756     const XObjectPtr
00757     group(
00758             XalanNode*              context,
00759             int                     opPos,
00760             XPathExecutionContext&  executionContext) const
00761     {
00762         return executeMore(context, opPos + 2, executionContext);
00763     }
00764 
00771     const XObjectPtr
00772     numberlit(
00773             XalanNode*              context,
00774             int                     opPos,
00775             XPathExecutionContext&  executionContext) const;
00776 
00783     const XObjectPtr
00784     arg(
00785             XalanNode*              context,
00786             int                     opPos,
00787             XPathExecutionContext&  executionContext) const
00788     {
00789         return executeMore(context, opPos + 2, executionContext);
00790     }
00791 
00799     const XObjectPtr
00800     locationPathPattern(
00801             XalanNode*              context,
00802             int                     opPos,
00803             XPathExecutionContext&  executionContext) const;
00804 
00808     const XObjectPtr
00809     runExtFunction(
00810             XalanNode*              context,
00811             int                     opPos,
00812             XPathExecutionContext&  executionContext) const;
00813 
00817     const XObjectPtr
00818     extfunction(
00819             XalanNode*                              context,
00820             int                                     /* opPos */,
00821             const XalanDOMString&                   theNamespace,
00822             const XalanDOMString&                   functionName, 
00823             const Function::XObjectArgVectorType&   argVec,
00824             XPathExecutionContext&                  executionContext) const
00825     {
00826         return  executionContext.extFunction(theNamespace,
00827                                              functionName,
00828                                              context,
00829                                              argVec,
00830                                              m_locator);
00831     }
00832 
00836     const XObjectPtr
00837     runFunction(
00838             XalanNode*              context,
00839             int                     opPos,
00840             XPathExecutionContext&  executionContext) const;
00841 
00845     const XObjectPtr
00846     function(
00847             XalanNode*                              context,
00848             int                                     funcID,
00849             const Function::XObjectArgVectorType&   argVec,
00850             XPathExecutionContext&                  executionContext) const
00851     {
00852         return s_functions[funcID].execute(executionContext, context, argVec, m_locator);
00853     }
00854 
00855     double
00856     getNumericOperand(
00857             XalanNode*              context,
00858             int                     opPos,
00859             XPathExecutionContext&  executionContext) const;
00860 
00861 private:
00862 
00863     // These are not implemented...
00864     XPath(const XPath&);
00865 
00866     XPath&
00867     operator=(const XPath&);
00868 
00869     bool
00870     operator==(const XPath&) const;
00871 
00872     // Default vector allocation sizes.
00873     enum
00874     {
00875         eDefaultTargetDataSize = 5
00876     };
00877 
00878     const XObjectPtr
00879     locationPath(
00880             XPathExecutionContext&  executionContext,
00881             XalanNode&              context, 
00882             int                     opPos) const;
00883 
00884     eMatchScore
00885     locationPathPattern(
00886             XPathExecutionContext&  executionContext,
00887             XalanNode&              context, 
00888             int                     opPos) const;
00889 
00890     class NodeTester
00891     {
00892     public:
00893 
00894         NodeTester(
00895             const XPath&            xpath,
00896             XPathExecutionContext&  executionContext,
00897             int                     opPos,
00898             int                     argLen,
00899             int                     stepType);
00900 
00901         eMatchScore
00902         operator()(
00903             const XalanNode&        context,
00904             XalanNode::NodeType     nodeType) const
00905         {
00906             assert(context.getNodeType() == nodeType);
00907 
00908             return (this->*m_testFunction)(context, nodeType);
00909         }
00910 
00911     private:
00912 
00913         typedef eMatchScore (NodeTester::*MemberFunctionPtr)(const XalanNode&, XalanNode::NodeType) const;
00914 
00915 
00916         eMatchScore
00917         testComment(
00918             const XalanNode&        context,
00919             XalanNode::NodeType     nodeType) const;
00920 
00921         eMatchScore
00922         testText(
00923             const XalanNode&        context,
00924             XalanNode::NodeType     nodeType) const;
00925 
00926         eMatchScore
00927         testPI(
00928             const XalanNode&        context,
00929             XalanNode::NodeType     nodeType) const;
00930 
00931         eMatchScore
00932         testPIName(
00933             const XalanNode&        context,
00934             XalanNode::NodeType     nodeType) const;
00935 
00936         eMatchScore
00937         testNode(
00938             const XalanNode&        context,
00939             XalanNode::NodeType     nodeType) const;
00940 
00941         eMatchScore
00942         testRoot(
00943             const XalanNode&        context,
00944             XalanNode::NodeType     nodeType) const;
00945 
00946         eMatchScore
00947         testAttributeNCName(
00948             const XalanNode&        context,
00949             XalanNode::NodeType     nodeType) const;
00950 
00951         eMatchScore
00952         testAttributeQName(
00953             const XalanNode&        context,
00954             XalanNode::NodeType     nodeType) const;
00955 
00956         eMatchScore
00957         testAttributeNamespaceOnly(
00958             const XalanNode&        context,
00959             XalanNode::NodeType     nodeType) const;
00960 
00961         eMatchScore
00962         testAttributeTotallyWild(
00963             const XalanNode&        context,
00964             XalanNode::NodeType     nodeType) const;
00965 
00966         eMatchScore
00967         testElementNCName(
00968             const XalanNode&        context,
00969             XalanNode::NodeType     nodeType) const;
00970 
00971         eMatchScore
00972         testElementQName(
00973             const XalanNode&        context,
00974             XalanNode::NodeType     nodeType) const;
00975 
00976         eMatchScore
00977         testElementNamespaceOnly(
00978             const XalanNode&        context,
00979             XalanNode::NodeType     nodeType) const;
00980 
00981         eMatchScore
00982         testElementTotallyWild(
00983             const XalanNode&        context,
00984             XalanNode::NodeType     nodeType) const;
00985 
00986         eMatchScore
00987         testNamespaceNCName(
00988             const XalanNode&        context,
00989             XalanNode::NodeType     nodeType) const;
00990 
00991         eMatchScore
00992         testNamespaceTotallyWild(
00993             const XalanNode&        context,
00994             XalanNode::NodeType     nodeType) const;
00995 
00996         eMatchScore
00997         testDefault(
00998             const XalanNode&        context,
00999             XalanNode::NodeType     nodeType) const;
01000 
01001         bool
01002         matchLocalName(const XalanNode&     context) const;
01003 
01004         bool
01005         matchNamespaceURI(const XalanNode&  context) const;
01006 
01007         bool
01008         matchLocalNameAndNamespaceURI(const XalanNode&  context) const;
01009 
01010         bool
01011         matchNamespace(const XalanNode&     context) const;
01012 
01013         bool
01014         shouldStripSourceNode(const XalanNode&  context) const;
01015 
01016         // Data members...
01017         XPathExecutionContext&  m_executionContext;
01018 
01019         const XalanDOMString*   m_targetNamespace;
01020 
01021         const XalanDOMString*   m_targetLocalName;
01022 
01023         MemberFunctionPtr       m_testFunction;
01024     };
01025 
01026 protected:
01027 
01028     void
01029     step(
01030             XPathExecutionContext&  executionContext,
01031             XalanNode*              context, 
01032             int                     opPos,
01033             MutableNodeRefList&     queryResults) const;
01034 
01045     XalanNode*
01046     stepPattern(
01047             XPathExecutionContext&  executionContext,
01048             XalanNode*              context, 
01049             int                     opPos,
01050             eMatchScore&            scoreHolder) const;
01051 
01052     int
01053     findNodeSet(
01054             XPathExecutionContext&  executionContext,
01055             XalanNode*              context, 
01056             int                     opPos,
01057             int                     stepType,
01058             MutableNodeRefList&     subQueryResults) const;
01059 
01060     int
01061     findRoot(
01062             XPathExecutionContext&  executionContext,
01063             XalanNode*              context, 
01064             int                     opPos,
01065             int                     stepType,
01066             MutableNodeRefList&     subQueryResults) const;
01067 
01068     int
01069     findParent(
01070             XPathExecutionContext&  executionContext,
01071             XalanNode*              context, 
01072             int                     opPos,
01073             int                     stepType,
01074             MutableNodeRefList&     subQueryResults) const;
01075 
01076     int
01077     findSelf(
01078             XPathExecutionContext&  executionContext,
01079             XalanNode*              context, 
01080             int                     opPos,
01081             int                     stepType,
01082             MutableNodeRefList&     subQueryResults) const;
01083 
01084     int
01085     findAncestors(
01086             XPathExecutionContext&  executionContext,
01087             XalanNode*              context, 
01088             int                     opPos,
01089             int                     stepType,
01090             MutableNodeRefList&     subQueryResults) const;
01091 
01092     int
01093     findAncestorsOrSelf(
01094             XPathExecutionContext&  executionContext,
01095             XalanNode*              context, 
01096             int                     opPos,
01097             int                     stepType,
01098             MutableNodeRefList&     subQueryResults) const;
01099 
01100     int
01101     findAttributes(
01102             XPathExecutionContext&  executionContext,
01103             XalanNode*              context, 
01104             int                     opPos,
01105             int                     stepType,
01106             MutableNodeRefList&     subQueryResults) const;
01107 
01108     int
01109     findChildren(
01110             XPathExecutionContext&  executionContext,
01111             XalanNode*              context, 
01112             int                     opPos,
01113             int                     stepType,
01114             MutableNodeRefList&     subQueryResults) const;
01115 
01116     int
01117     findDescendants(
01118             XPathExecutionContext&  executionContext,
01119             XalanNode*              context, 
01120             int                     opPos,
01121             int                     stepType,
01122             MutableNodeRefList&     subQueryResults) const;
01123 
01124     int
01125     findFollowing(
01126             XPathExecutionContext&  executionContext,
01127             XalanNode*              context, 
01128             int                     opPos,
01129             int                     stepType,
01130             MutableNodeRefList&     subQueryResults) const;
01131 
01132     int
01133     findFollowingSiblings(
01134             XPathExecutionContext&  executionContext,
01135             XalanNode*              context, 
01136             int                     opPos,
01137             int                     stepType,
01138             MutableNodeRefList&     subQueryResults) const;
01139 
01140     int
01141     findPreceeding(
01142             XPathExecutionContext&  executionContext,
01143             XalanNode*              context, 
01144             int                     opPos,
01145             int                     stepType,
01146             MutableNodeRefList&     subQueryResults) const;
01147 
01148     int
01149     findPreceedingSiblings(
01150             XPathExecutionContext&  executionContext,
01151             XalanNode*              context, 
01152             int                     opPos,
01153             int                     stepType,
01154             MutableNodeRefList&     subQueryResults) const;
01155 
01156     int
01157     findNamespace(
01158             XPathExecutionContext&  executionContext,
01159             XalanNode*              context, 
01160             int                     opPos,
01161             int                     stepType,
01162             MutableNodeRefList&     subQueryResults) const;
01163 
01164     int
01165     findNodesOnUnknownAxis(
01166             XPathExecutionContext&  executionContext,
01167             XalanNode*              context, 
01168             int                     opPos,
01169             int                     stepType,
01170             MutableNodeRefList&     subQueryResults) const;
01171 
01172     eMatchScore
01173     nodeTest(
01174             XPathExecutionContext&  executionContext,
01175             XalanNode*              context,
01176             XalanNode::NodeType     nodeType,
01177             int                     opPos,
01178             int                     argLen,
01179             int                     stepType) const;
01180 
01181     void
01182     predicates(
01183             XPathExecutionContext&  executionContext,
01184             XalanNode*              context, 
01185             int                     opPos,
01186             MutableNodeRefList&     subQueryResults,
01187             int&                    endPredicatesPos) const;
01188 
01189     eMatchScore
01190     handleFoundIndex(
01191             XPathExecutionContext&  executionContext,
01192             XalanNode*              localContext,
01193             int                     startOpPos) const;
01194 
01195     eMatchScore
01196     handleFoundIndexPositional(
01197             XPathExecutionContext&  executionContext,
01198             XalanNode*              localContext,
01199             int                     startOpPos) const;
01200 
01201     // Data members...
01202 
01208     XPathExpression                     m_expression;
01209 
01213     const Locator*                      m_locator;
01214 
01220     bool                                m_inStylesheet;
01221 
01227     static FunctionTableType            s_functions;
01228 
01229     static const XalanDOMString         s_emptyString;
01230 };
01231 
01232 
01233 
01234 #endif  // XPATH_HEADER_GUARD_1357924680

Interpreting class diagrams

Doxygen and GraphViz are used to generate this API documentation from the Xalan-C header files.

Xalan-C++ XSLT Processor Version 1.4
Copyright © 2000, 2001, 2002 The Apache Software Foundation. All Rights Reserved.