Xalan-C++ API Documentation

The Xalan C++ XSLT Processor Version 1.8

Main Page | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members | Related Pages

XPathEvaluator.hpp

Go to the documentation of this file.
00001 /*
00002  * Copyright 1999-2004 The Apache Software Foundation.
00003  *
00004  * Licensed under the Apache License, Version 2.0 (the "License");
00005  * you may not use this file except in compliance with the License.
00006  * You may obtain a copy of the License at
00007  *
00008  *     http://www.apache.org/licenses/LICENSE-2.0
00009  *
00010  * Unless required by applicable law or agreed to in writing, software
00011  * distributed under the License is distributed on an "AS IS" BASIS,
00012  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013  * See the License for the specific language governing permissions and
00014  * limitations under the License.
00015  */
00016 #if !defined(XPATHEVALUATOR_HEADER_GUARD_1357924680)
00017 #define XPATHEVALUATOR_HEADER_GUARD_1357924680
00018 
00019 
00020 
00021 #include <xalanc/XPath/XPathDefinitions.hpp>
00022 
00023 
00024 
00025 #if defined(XALAN_AUTO_PTR_REQUIRES_DEFINITION)
00026 #include <xalanc/XPath/XObjectFactory.hpp>
00027 #include <xalanc/XPath/XPathFactoryDefault.hpp>
00028 #include <xalanc/XPath/XPathConstructionContextDefault.hpp>
00029 #include <xalanc/XPath/XPathExecutionContextDefault.hpp>
00030 #endif
00031 
00032 
00033 
00034 #include <xalanc/Include/XalanAutoPtr.hpp>
00035 
00036 
00037 
00038 #include <xalanc/XalanDOM/XalanDOMString.hpp>
00039 
00040 
00041 
00042 XALAN_CPP_NAMESPACE_BEGIN
00043 
00044 
00045 
00046 #if !defined(XALAN_AUTO_PTR_REQUIRES_DEFINITION)
00047 class XObjectFactory;
00048 class XPathFactoryDefault;
00049 class XPathConstructionContextDefault;
00050 class XPathExecutionContextDefault;
00051 #endif
00052 
00053 
00054 
00055 class DOMSupport;
00056 class NodeRefList;
00057 class PrefixResolver;
00058 class XalanNode;
00059 class XalanElement;
00060 class XObjectPtr;
00061 class XPath;
00062 class XPathEnvSupport;
00063 
00064 
00065 
00066 class XALAN_XPATH_EXPORT XPathEvaluator
00067 {
00068 public:
00069 
00070     // Static initializer to be called before any instances are
00071     // created.  The call is _not_ thread-safe, you must only call
00072     // it once, unless you have called terminate previously, and
00073     // you want to re-initialize the library.
00074     static void
00075     initialize();
00076 
00077     // Static terminator to be called after all instances
00078     // are destroyed.  The call is _not_ thread-safe.  Once
00079     // terminated, you can call initialize() again, to
00080     // re-initialize the library.
00081     static void
00082     terminate();
00083 
00084 
00085     XPathEvaluator();
00086 
00087     ~XPathEvaluator();
00088 
00100     XalanNode*
00101     selectSingleNode(
00102             DOMSupport&             domSupport,
00103             XalanNode*              contextNode,
00104             const XalanDOMChar*     xpathString,
00105             const XalanElement*     namespaceNode = 0);
00106 
00118     XalanNode*
00119     selectSingleNode(
00120             DOMSupport&             domSupport,
00121             XalanNode*              contextNode,
00122             const XalanDOMChar*     xpathString,
00123             const PrefixResolver&   prefixResolver);
00124 
00136     XalanNode*
00137     selectSingleNode(
00138             DOMSupport&             domSupport,
00139             XalanNode*              contextNode,
00140             const XPath&            xpath,
00141             const XalanElement*     namespaceNode = 0);
00142 
00154     XalanNode*
00155     selectSingleNode(
00156             DOMSupport&             domSupport,
00157             XalanNode*              contextNode,
00158             const XPath&            xpath,
00159             const PrefixResolver&   prefixResolver);
00160 
00171     NodeRefList
00172     selectNodeList(
00173             DOMSupport&             domSupport,
00174             XalanNode*              contextNode,
00175             const XalanDOMChar*     xpathString,
00176             const XalanElement*     namespaceNode = 0);
00177 
00188     NodeRefList
00189     selectNodeList(
00190             DOMSupport&             domSupport,
00191             XalanNode*              contextNode,
00192             const XalanDOMChar*     xpathString,
00193             const PrefixResolver&   prefixResolver);
00194 
00205     NodeRefList
00206     selectNodeList(
00207             DOMSupport&             domSupport,
00208             XalanNode*              contextNode,
00209             const XPath&            xpath,
00210             const XalanElement*     namespaceNode = 0);
00211 
00222     NodeRefList
00223     selectNodeList(
00224             DOMSupport&             domSupport,
00225             XalanNode*              contextNode,
00226             const XPath&            xpath,
00227             const PrefixResolver&   prefixResolver);
00228 
00245     XObjectPtr
00246     evaluate(
00247             DOMSupport&             domSupport,
00248             XalanNode*              contextNode,
00249             const XalanDOMChar*     xpathString,
00250             const XalanElement*     namespaceNode = 0);
00251 
00268     XObjectPtr
00269     evaluate(
00270             DOMSupport&             domSupport,
00271             XalanNode*              contextNode,
00272             const XalanDOMChar*     xpathString,
00273             const PrefixResolver&   prefixResolver);
00274 
00291     XObjectPtr
00292     evaluate(
00293             DOMSupport&             domSupport,
00294             XalanNode*              contextNode,
00295             const XPath&            xpath,
00296             const XalanElement*     namespaceNode = 0);
00297 
00314     XObjectPtr
00315     evaluate(
00316             DOMSupport&             domSupport,
00317             XalanNode*              contextNode,
00318             const XPath&            xpath,
00319             const PrefixResolver&   prefixResolver);
00320 
00331     XPath*
00332     createXPath(const XalanDOMChar*     xpathString);
00333 
00344     XPath*
00345     createXPath(
00346             const XalanDOMChar*     xpathString,
00347             DOMSupport&             domSupport,
00348             const XalanElement*     namespaceNode);
00349 
00359     XPath*
00360     createXPath(
00361             const XalanDOMChar*     xpathString,
00362             const PrefixResolver&   prefixResolver);
00363 
00371     bool
00372     destroyXPath(XPath*     theXPath);
00373 
00374 private:
00375 
00387     XObjectPtr
00388     evaluate(
00389             DOMSupport&             domSupport,
00390             XalanNode*              contextNode,
00391             const XalanDOMChar*     xpathString,
00392             const PrefixResolver&   prefixResolver,
00393             XPathEnvSupport&        envSupport);
00394 
00406     XObjectPtr
00407     evaluate(
00408             DOMSupport&             domSupport,
00409             XalanNode*              contextNode,
00410             const XPath&            xpath,
00411             const PrefixResolver&   prefixResolver,
00412             XPathEnvSupport&        envSupport);
00413 
00414     // Data members...
00415     const XalanAutoPtr<XObjectFactory>                  m_xobjectFactory;
00416 
00417     const XalanAutoPtr<XPathFactoryDefault>             m_xpathFactory;
00418 
00419     const XalanAutoPtr<XPathConstructionContextDefault> m_constructionContext;
00420 
00421     const XalanAutoPtr<XPathExecutionContextDefault>    m_executionContext;
00422 };
00423 
00424 
00425 
00426 XALAN_CPP_NAMESPACE_END
00427 
00428 
00429 
00430 #endif  // XPATHEVALUATOR_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.8
Copyright © 1999-2004 The Apache Software Foundation. All Rights Reserved.