Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:15:20

0001 /*
0002  * Licensed to the Apache Software Foundation (ASF) under one or more
0003  * contributor license agreements.  See the NOTICE file distributed with
0004  * this work for additional information regarding copyright ownership.
0005  * The ASF licenses this file to You under the Apache License, Version 2.0
0006  * (the "License"); you may not use this file except in compliance with
0007  * the License.  You may obtain a copy of the License at
0008  * 
0009  *      http://www.apache.org/licenses/LICENSE-2.0
0010  * 
0011  * Unless required by applicable law or agreed to in writing, software
0012  * distributed under the License is distributed on an "AS IS" BASIS,
0013  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
0014  * See the License for the specific language governing permissions and
0015  * limitations under the License.
0016  */
0017 
0018 /*
0019  * $Id$
0020  */
0021 
0022 #if !defined(XERCESC_INCLUDE_GUARD_XUTIL_HPP)
0023 #define XERCESC_INCLUDE_GUARD_XUTIL_HPP
0024 
0025 #include <xercesc/dom/DOMElement.hpp>
0026 #include <xercesc/dom/DOMDocument.hpp>
0027 #include <xercesc/dom/DOMNamedNodeMap.hpp>
0028 #include <xercesc/dom/DOMNode.hpp>
0029 
0030 XERCES_CPP_NAMESPACE_BEGIN
0031 
0032 class DOMNode;
0033 class DOMElement;
0034 
0035 /**
0036  * Some useful utility methods.
0037  */
0038 class VALIDATORS_EXPORT XUtil
0039 {
0040 public:
0041 
0042     // Finds and returns the first child element node.
0043     static DOMElement* getFirstChildElement(const DOMNode* const parent);
0044 
0045     // Finds and returns the first child node with the given qualifiedname.
0046     static DOMElement* getFirstChildElementNS(const DOMNode* const parent
0047                                               , const XMLCh** const elemNames
0048                                               , const XMLCh* const uriStr
0049                                               , unsigned int       length);
0050 
0051     // Finds and returns the next sibling element node.
0052     static DOMElement* getNextSiblingElement(const DOMNode* const node);
0053 
0054     static DOMElement* getNextSiblingElementNS(const DOMNode* const node
0055                                                , const XMLCh** const elemNames
0056                                                , const XMLCh* const uriStr
0057                                                , unsigned int        length);
0058 
0059 private:
0060     // -----------------------------------------------------------------------
0061     //  Constructors and Destructor
0062     // -----------------------------------------------------------------------
0063 
0064     // This class cannot be instantiated.
0065      XUtil() {};
0066     ~XUtil() {};
0067 };
0068 
0069 XERCES_CPP_NAMESPACE_END
0070 
0071 #endif