source: NonGTP/Xerces/xerces-c_2_8_0/include/xercesc/dom/DOMXPathNSResolver.hpp @ 2674

Revision 2674, 3.8 KB checked in by mattausch, 16 years ago (diff)
Line 
1#ifndef DOMXPathNSResolver_HEADER_GUARD_
2#define DOMXPathNSResolver_HEADER_GUARD_
3
4/*
5 * Licensed to the Apache Software Foundation (ASF) under one or more
6 * contributor license agreements.  See the NOTICE file distributed with
7 * this work for additional information regarding copyright ownership.
8 * The ASF licenses this file to You under the Apache License, Version 2.0
9 * (the "License"); you may not use this file except in compliance with
10 * the License.  You may obtain a copy of the License at
11 *
12 *      http://www.apache.org/licenses/LICENSE-2.0
13 *
14 * Unless required by applicable law or agreed to in writing, software
15 * distributed under the License is distributed on an "AS IS" BASIS,
16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 * See the License for the specific language governing permissions and
18 * limitations under the License.
19 */
20
21#include <xercesc/util/XercesDefs.hpp>
22
23XERCES_CPP_NAMESPACE_BEGIN
24/**
25 * The <code>DOMXPathNSResolver</code> interface permit prefix strings
26 * in the expression to be properly bound to namespaceURI strings.
27 * <code>DOMXPathEvaluator</code> can construct an implementation of
28 * <code>DOMXPathNSResolver</code> from a node, or the interface may be
29 * implemented by any application.
30 * @since DOM Level 3
31 */
32class CDOM_EXPORT DOMXPathNSResolver
33{
34
35protected:
36    // -----------------------------------------------------------------------
37    //  Hidden constructors
38    // -----------------------------------------------------------------------
39    /** @name Hidden constructors */
40    //@{   
41    DOMXPathNSResolver() {};
42    //@}
43
44private:
45    // -----------------------------------------------------------------------
46    // Unimplemented constructors and operators
47    // -----------------------------------------------------------------------
48    /** @name Unimplemented constructors and operators */
49    //@{
50    DOMXPathNSResolver(const DOMXPathNSResolver &);
51    DOMXPathNSResolver& operator = (const  DOMXPathNSResolver&);
52    //@}
53
54public:
55    // -----------------------------------------------------------------------
56    //  All constructors are hidden, just the destructor is available
57    // -----------------------------------------------------------------------
58    /** @name Destructor */
59    //@{
60    /**
61     * Destructor
62     *
63     */
64    virtual ~DOMXPathNSResolver() {};
65    //@}
66
67    // -----------------------------------------------------------------------
68    // Virtual DOMDocument interface
69    // -----------------------------------------------------------------------
70    /** @name Functions introduced in DOM Level 3 */
71    //@{
72
73    /** Look up the namespace URI associated to the given namespace prefix.
74     * The XPath evaluator must never call this with a null or empty argument,
75     * because the result of doing this is undefined.
76     * @param prefix of type XMLCh - The prefix to look for.
77     * @return the associated namespace URI or null if none is found.
78     */
79    virtual const XMLCh*          lookupNamespaceURI(const XMLCh* prefix) const = 0;
80    //@}
81
82
83    // -----------------------------------------------------------------------
84    // Non-standard extension
85    // -----------------------------------------------------------------------
86    /** @name Non-standard extension */
87    //@{
88
89    /**
90     * Non-standard extension
91     *
92     * XPath2 implementations require a reverse lookup in the static context.
93     * Look up the prefix associated with the namespace URI
94     * The XPath evaluator must never call this with a null or empty argument,
95     * because the result of doing this is undefined.
96     * @param URI of type XMLCh - The namespace to look for.
97     * @return the associated prefix or null if none is found.
98     */
99    virtual const XMLCh*          lookupPrefix(const XMLCh* URI) const = 0;
100
101
102    //@}
103};
104
105XERCES_CPP_NAMESPACE_END
106
107#endif
108
Note: See TracBrowser for help on using the repository browser.