## Xalan-C++ API Documentation

### The Xalan C++ XSLT Processor Version 1.10

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

# XalanDocumentPrefixResolver.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(XALANDOCUMENTPREFIXRESOLVER_HEADER_GUARD_1357924680)
    00017 #define XALANDOCUMENTPREFIXRESOLVER_HEADER_GUARD_1357924680
    00018
    00019
    00020
    00021 // Base include file.  Must be first.
    00022 #include <xalanc/DOMSupport/DOMSupportDefinitions.hpp>
    00023
    00024
    00025
    00026 #include <xalanc/XalanDOM/XalanDOMString.hpp>
    00027
    00028
    00029
    00030 #include <xalanc/PlatformSupport/PrefixResolver.hpp>
    00031 #include <xalanc/PlatformSupport/DOMStringHelper.hpp>
    00032
    00033
    00034
    00035 #include <xalanc/Include/XalanVector.hpp>
    00036 #include <xalanc/Include/XalanMap.hpp>
    00037 #include <xalanc/Include/STLHelper.hpp>
    00038
    00039
    00040
    00041 #include <xalanc/DOMSupport/TreeWalker.hpp>
    00042
    00043
    00044
    00045 XALAN_CPP_NAMESPACE_BEGIN
    00046
    00047
    00048
    00049
    00050
    00051 class XalanAttr;
    00052 class XalanDocument;
    00053
    00054 typedef XalanVector<const XalanNode*>               AttributeVectorTypeDecl;
    00055 XALAN_USES_MEMORY_MANAGER(AttributeVectorTypeDecl)
    00056
    00057
    00058 class XALAN_DOMSUPPORT_EXPORT XalanDocumentPrefixResolver : public PrefixResolver
    00059 {
    00060 public:
    00061
    00062     typedef AttributeVectorTypeDecl                     AttributeVectorType;
    00063     typedef XalanMap<const XalanDOMString*,
    00064                     AttributeVectorType>                NamespacesMapType;
    00065
    00072     XalanDocumentPrefixResolver(
    00073             const XalanDocument*    theDocument,
    00074             const XalanDOMString&   theURI = XalanDOMString(XalanMemMgrs::getDummyMemMgr()),
    00075             MemoryManagerType&      theManager XALAN_DEFAULT_MEMMGR);
    00076
    00077     virtual
    00078     ~XalanDocumentPrefixResolver();
    00079
    00080
    00081     virtual const XalanDOMString*
    00082     getNamespaceForPrefix(const XalanDOMString&     prefix) const;
    00083
    00084     virtual const XalanDOMString&
    00085     getURI() const;
    00086
    00090     class NamespaceNodesTreeWalker : public TreeWalker
    00091     {
    00092     public:
    00093
    00094         NamespaceNodesTreeWalker(NamespacesMapType&     theMap);
    00095
    00096         virtual
    00097         ~NamespaceNodesTreeWalker();
    00098
    00099     protected:
    00100
    00101         virtual bool
    00102         startNode(const XalanNode*  node);
    00103
    00104         virtual bool
    00105         startNode(XalanNode*    node);
    00106
    00107         virtual bool
    00108         endNode(const XalanNode*    node);
    00109
    00110         virtual bool
    00111         endNode(XalanNode*  node);
    00112
    00113     private:
    00114
    00115         NamespacesMapType&  m_map;
    00116     };
    00117
    00118
    00119 protected:
    00120
    00129     virtual const XalanDOMString*
    00130     duplicateBinding(const AttributeVectorType&     theVector) const;
    00131
    00132 private:
    00133
    00134     NamespacesMapType       m_namespaces;
    00135
    00136     const XalanDOMString    m_uri;
    00137 };
    00138
    00139
    00140
    00141 XALAN_CPP_NAMESPACE_END
    00142
    00143
    00144
    00145 #endif  // XALANDOCUMENTPREFIXRESOLVER_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.10 Copyright © 1999-2004 The Apache Software Foundation. All Rights Reserved.