secureswitools/swisistools/source/xmlparser/xerces/include/xercesc/dom/DOMDocumentType.hpp
changeset 0 ba25891c3a9e
child 1 c42dffbd5b4f
equal deleted inserted replaced
-1:000000000000 0:ba25891c3a9e
       
     1 /*
       
     2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description: 
       
    15 *
       
    16 */
       
    17 #ifndef DOMDocumentType_HEADER_GUARD_
       
    18 #define DOMDocumentType_HEADER_GUARD_
       
    19 
       
    20 
       
    21 /*
       
    22  * Licensed to the Apache Software Foundation (ASF) under one or more
       
    23  * contributor license agreements.  See the NOTICE file distributed with
       
    24  * this work for additional information regarding copyright ownership.
       
    25  * The ASF licenses this file to You under the Apache License, Version 2.0
       
    26  * (the "License"); you may not use this file except in compliance with
       
    27  * the License.  You may obtain a copy of the License at
       
    28  * 
       
    29  *      http://www.apache.org/licenses/LICENSE-2.0
       
    30  * 
       
    31  * Unless required by applicable law or agreed to in writing, software
       
    32  * distributed under the License is distributed on an "AS IS" BASIS,
       
    33  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
       
    34  * See the License for the specific language governing permissions and
       
    35  * limitations under the License.
       
    36  */
       
    37 
       
    38 /*
       
    39  * $Id: DOMDocumentType.hpp 568078 2007-08-21 11:43:25Z amassari $
       
    40  */
       
    41 
       
    42 #include <xercesc/util/XercesDefs.hpp>
       
    43 #include <xercesc/dom/DOMNode.hpp>
       
    44 
       
    45 XERCES_CPP_NAMESPACE_BEGIN
       
    46 
       
    47 
       
    48 class DOMNamedNodeMap;
       
    49 
       
    50 /**
       
    51  * Each <code>DOMDocument</code> has a <code>doctype</code> attribute whose value
       
    52  * is either <code>null</code> or a <code>DOMDocumentType</code> object. The
       
    53  * <code>DOMDocumentType</code> interface in the DOM Core provides an interface
       
    54  * to the list of entities that are defined for the document, and little
       
    55  * else because the effect of namespaces and the various XML schema efforts
       
    56  * on DTD representation are not clearly understood as of this writing.
       
    57  * <p>The DOM Level 2 doesn't support editing <code>DOMDocumentType</code> nodes.
       
    58  * <p>See also the <a href='http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113'>Document Object Model (DOM) Level 2 Core Specification</a>.
       
    59  *
       
    60  * @since DOM Level 1
       
    61  */
       
    62 class CDOM_EXPORT DOMDocumentType: public DOMNode {
       
    63 protected:
       
    64     // -----------------------------------------------------------------------
       
    65     //  Hidden constructors
       
    66     // -----------------------------------------------------------------------
       
    67     /** @name Hidden constructors */
       
    68     //@{    
       
    69     DOMDocumentType() {};
       
    70     //@}
       
    71 
       
    72 private:
       
    73     // -----------------------------------------------------------------------
       
    74     // Unimplemented constructors and operators
       
    75     // -----------------------------------------------------------------------
       
    76     /** @name Unimplemented constructors and operators */
       
    77     //@{
       
    78     DOMDocumentType(const DOMDocumentType &);
       
    79     DOMDocumentType & operator = (const DOMDocumentType &);
       
    80     //@}
       
    81 
       
    82 public:
       
    83     // -----------------------------------------------------------------------
       
    84     //  All constructors are hidden, just the destructor is available
       
    85     // -----------------------------------------------------------------------
       
    86     /** @name Destructor */
       
    87     //@{
       
    88     /**
       
    89      * Destructor
       
    90      *
       
    91      */
       
    92     virtual ~DOMDocumentType() {};
       
    93     //@}
       
    94 
       
    95     // -----------------------------------------------------------------------
       
    96     //  Virtual DOMDocumentType interface
       
    97     // -----------------------------------------------------------------------
       
    98     /** @name Functions introduced in DOM Level 1 */
       
    99     //@{
       
   100     /**
       
   101      * The name of DTD; i.e., the name immediately following the
       
   102      * <code>DOCTYPE</code> keyword.
       
   103      *
       
   104      * @since DOM Level 1
       
   105      */
       
   106     virtual const XMLCh *       getName() const = 0;
       
   107 
       
   108     /**
       
   109      * A <code>DOMNamedNodeMap</code> containing the general entities, both
       
   110      * external and internal, declared in the DTD. Parameter entities are
       
   111      * not contained. Duplicates are discarded. For example in:
       
   112      * <code>&lt;!DOCTYPE<br>
       
   113      * ex SYSTEM "ex.dtd" [ &lt;!ENTITY foo "foo"&gt; &lt;!ENTITY bar<br>
       
   114      * "bar"&gt; &lt;!ENTITY bar "bar2"&gt; &lt;!ENTITY % baz "baz"&gt;<br>
       
   115      * ]&gt; &lt;ex/&gt;<br></code>
       
   116      *  the interface provides access to <code>foo</code>
       
   117      * and the first declaration of <code>bar</code> but not the second
       
   118      * declaration of <code>bar</code> or <code>baz</code>. Every node in
       
   119      * this map also implements the <code>DOMEntity</code> interface.
       
   120      * <br>The DOM Level 2 does not support editing entities, therefore
       
   121      * <code>entities</code> cannot be altered in any way.
       
   122      *
       
   123      * @since DOM Level 1
       
   124      */
       
   125     virtual DOMNamedNodeMap *getEntities() const = 0;
       
   126 
       
   127 
       
   128     /**
       
   129      * A <code>DOMNamedNodeMap</code> containing the notations declared in the
       
   130      * DTD. Duplicates are discarded. Every node in this map also implements
       
   131      * the <code>DOMNotation</code> interface.
       
   132      * <br>The DOM Level 2 does not support editing notations, therefore
       
   133      * <code>notations</code> cannot be altered in any way.
       
   134      *
       
   135      * @since DOM Level 1
       
   136      */
       
   137     virtual DOMNamedNodeMap *getNotations() const = 0;
       
   138     //@}
       
   139 
       
   140     /** @name Functions introduced in DOM Level 2. */
       
   141     //@{
       
   142     /**
       
   143      * Get the public identifier of the external subset.
       
   144      *
       
   145      * @return The public identifier of the external subset.
       
   146      * @since DOM Level 2
       
   147      */
       
   148     virtual const XMLCh *     getPublicId() const = 0;
       
   149 
       
   150     /**
       
   151      * Get the system identifier of the external subset.
       
   152      *
       
   153      * @return The system identifier of the external subset.
       
   154      * @since DOM Level 2
       
   155      */
       
   156     virtual const XMLCh *     getSystemId() const = 0;
       
   157 
       
   158     /**
       
   159      * The internal subset as a string, or <code>null</code> if there is none.
       
   160      * This is does not contain the delimiting square brackets.The actual
       
   161      * content returned depends on how much information is available to the
       
   162      * implementation. This may vary depending on various parameters,
       
   163      * including the XML processor used to build the document.
       
   164      *
       
   165      * @return The internal subset as a string.
       
   166      * @since DOM Level 2
       
   167      */
       
   168     virtual const XMLCh *     getInternalSubset() const = 0;
       
   169     //@}
       
   170 
       
   171 };
       
   172 
       
   173 XERCES_CPP_NAMESPACE_END
       
   174 
       
   175 #endif
       
   176 
       
   177