Eneboo - Documentación para desarrolladores
|
00001 /**************************************************************************** 00002 ** $Id: qt/qdom.h 3.3.8 edited Jan 11 14:39 $ 00003 ** 00004 ** Definition of QDomDocument and related classes. 00005 ** 00006 ** Created : 000518 00007 ** 00008 ** Copyright (C) 1992-2007 Trolltech ASA. All rights reserved. 00009 ** 00010 ** This file is part of the xml module of the Qt GUI Toolkit. 00011 ** 00012 ** This file may be distributed under the terms of the Q Public License 00013 ** as defined by Trolltech ASA of Norway and appearing in the file 00014 ** LICENSE.QPL included in the packaging of this file. 00015 ** 00016 ** This file may be distributed and/or modified under the terms of the 00017 ** GNU General Public License version 2 as published by the Free Software 00018 ** Foundation and appearing in the file LICENSE.GPL included in the 00019 ** packaging of this file. 00020 ** 00021 ** Licensees holding valid Qt Enterprise Edition licenses may use this 00022 ** file in accordance with the Qt Commercial License Agreement provided 00023 ** with the Software. 00024 ** 00025 ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 00026 ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 00027 ** 00028 ** See http://www.trolltech.com/pricing.html or email sales@trolltech.com for 00029 ** information about Qt Commercial License Agreements. 00030 ** See http://www.trolltech.com/qpl/ for QPL licensing information. 00031 ** See http://www.trolltech.com/gpl/ for GPL licensing information. 00032 ** 00033 ** Contact info@trolltech.com if any conditions of this licensing are 00034 ** not clear to you. 00035 ** 00036 **********************************************************************/ 00037 00038 #ifndef QDOM_H 00039 #define QDOM_H 00040 00041 #ifndef QT_H 00042 #include "qstring.h" 00043 #endif // QT_H 00044 00045 #if !defined(QT_MODULE_XML) || defined( QT_LICENSE_PROFESSIONAL ) || defined( QT_INTERNAL_XML ) 00046 #define QM_EXPORT_DOM 00047 #else 00048 #define QM_EXPORT_DOM Q_EXPORT 00049 #endif 00050 00051 #ifndef QT_NO_DOM 00052 00053 class QIODevice; 00054 class QTextStream; 00055 00056 class QXmlInputSource; 00057 class QXmlReader; 00058 00059 class QDomDocumentPrivate; 00060 class QDomDocumentTypePrivate; 00061 class QDomDocumentFragmentPrivate; 00062 class QDomNodePrivate; 00063 class QDomNodeListPrivate; 00064 class QDomImplementationPrivate; 00065 class QDomElementPrivate; 00066 class QDomNotationPrivate; 00067 class QDomEntityPrivate; 00068 class QDomEntityReferencePrivate; 00069 class QDomProcessingInstructionPrivate; 00070 class QDomAttrPrivate; 00071 class QDomCharacterDataPrivate; 00072 class QDomTextPrivate; 00073 class QDomCommentPrivate; 00074 class QDomCDATASectionPrivate; 00075 class QDomNamedNodeMapPrivate; 00076 class QDomImplementationPrivate; 00077 00078 class QDomNodeList; 00079 class QDomElement; 00080 class QDomText; 00081 class QDomComment; 00082 class QDomCDATASection; 00083 class QDomProcessingInstruction; 00084 class QDomAttr; 00085 class QDomEntityReference; 00086 class QDomDocument; 00087 class QDomNamedNodeMap; 00088 class QDomDocument; 00089 class QDomDocumentFragment; 00090 class QDomDocumentType; 00091 class QDomImplementation; 00092 class QDomNode; 00093 class QDomEntity; 00094 class QDomNotation; 00095 class QDomCharacterData; 00096 00097 class QM_EXPORT_DOM QDomImplementation 00098 { 00099 public: 00100 QDomImplementation(); 00101 QDomImplementation( const QDomImplementation& ); 00102 virtual ~QDomImplementation(); 00103 QDomImplementation& operator= ( const QDomImplementation& ); 00104 bool operator== ( const QDomImplementation& ) const; 00105 bool operator!= ( const QDomImplementation& ) const; 00106 00107 // functions 00108 virtual bool hasFeature( const QString& feature, const QString& version ); 00109 virtual QDomDocumentType createDocumentType( const QString& qName, const QString& publicId, const QString& systemId ); 00110 virtual QDomDocument createDocument( const QString& nsURI, const QString& qName, const QDomDocumentType& doctype ); 00111 00112 // Qt extension 00113 bool isNull(); 00114 00115 private: 00116 QDomImplementationPrivate* impl; 00117 QDomImplementation( QDomImplementationPrivate* ); 00118 00119 friend class QDomDocument; 00120 }; 00121 00122 class QM_EXPORT_DOM QDomNode 00123 { 00124 public: 00125 enum NodeType { 00126 ElementNode = 1, 00127 AttributeNode = 2, 00128 TextNode = 3, 00129 CDATASectionNode = 4, 00130 EntityReferenceNode = 5, 00131 EntityNode = 6, 00132 ProcessingInstructionNode = 7, 00133 CommentNode = 8, 00134 DocumentNode = 9, 00135 DocumentTypeNode = 10, 00136 DocumentFragmentNode = 11, 00137 NotationNode = 12, 00138 BaseNode = 21,// this is not in the standard 00139 CharacterDataNode = 22 // this is not in the standard 00140 }; 00141 00142 QDomNode(); 00143 QDomNode( const QDomNode& ); 00144 QDomNode& operator= ( const QDomNode& ); 00145 bool operator== ( const QDomNode& ) const; 00146 bool operator!= ( const QDomNode& ) const; 00147 virtual ~QDomNode(); 00148 00149 // DOM functions 00150 virtual QDomNode insertBefore( const QDomNode& newChild, const QDomNode& refChild ); 00151 virtual QDomNode insertAfter( const QDomNode& newChild, const QDomNode& refChild ); 00152 virtual QDomNode replaceChild( const QDomNode& newChild, const QDomNode& oldChild ); 00153 virtual QDomNode removeChild( const QDomNode& oldChild ); 00154 virtual QDomNode appendChild( const QDomNode& newChild ); 00155 virtual bool hasChildNodes() const; 00156 virtual QDomNode cloneNode( bool deep = TRUE ) const; 00157 virtual void normalize(); 00158 virtual bool isSupported( const QString& feature, const QString& version ) const; 00159 00160 // DOM read only attributes 00161 virtual QString nodeName() const; 00162 virtual QDomNode::NodeType nodeType() const; 00163 virtual QDomNode parentNode() const; 00164 virtual QDomNodeList childNodes() const; 00165 virtual QDomNode firstChild() const; 00166 virtual QDomNode lastChild() const; 00167 virtual QDomNode previousSibling() const; 00168 virtual QDomNode nextSibling() const; 00169 virtual QDomNamedNodeMap attributes() const; 00170 virtual QDomDocument ownerDocument() const; 00171 virtual QString namespaceURI() const; 00172 virtual QString localName() const; 00173 virtual bool hasAttributes() const; 00174 00175 // DOM attributes 00176 virtual QString nodeValue() const; 00177 virtual void setNodeValue( const QString& ); 00178 virtual QString prefix() const; 00179 virtual void setPrefix( const QString& pre ); 00180 00181 // Qt extensions 00182 virtual bool isAttr() const; 00183 virtual bool isCDATASection() const; 00184 virtual bool isDocumentFragment() const; 00185 virtual bool isDocument() const; 00186 virtual bool isDocumentType() const; 00187 virtual bool isElement() const; 00188 virtual bool isEntityReference() const; 00189 virtual bool isText() const; 00190 virtual bool isEntity() const; 00191 virtual bool isNotation() const; 00192 virtual bool isProcessingInstruction() const; 00193 virtual bool isCharacterData() const; 00194 virtual bool isComment() const; 00195 00200 QDomNode namedItem( const QString& name ) const; 00201 00202 bool isNull() const; 00203 void clear(); 00204 00205 QDomAttr toAttr(); 00206 QDomCDATASection toCDATASection(); 00207 QDomDocumentFragment toDocumentFragment(); 00208 QDomDocument toDocument(); 00209 QDomDocumentType toDocumentType(); 00210 QDomElement toElement(); 00211 QDomEntityReference toEntityReference(); 00212 QDomText toText(); 00213 QDomEntity toEntity(); 00214 QDomNotation toNotation(); 00215 QDomProcessingInstruction toProcessingInstruction(); 00216 QDomCharacterData toCharacterData(); 00217 QDomComment toComment(); 00218 00219 void save( QTextStream&, int ) const; 00220 00221 //### AbanQ Optimization Hack 00222 void * internalImpl() const { return impl; } 00223 //### 00224 00225 protected: 00226 QDomNodePrivate* impl; 00227 QDomNode( QDomNodePrivate* ); 00228 00229 private: 00230 friend class QDomDocument; 00231 friend class QDomDocumentType; 00232 friend class QDomNodeList; 00233 friend class QDomNamedNodeMap; 00234 }; 00235 00236 class QM_EXPORT_DOM QDomNodeList 00237 { 00238 public: 00239 QDomNodeList(); 00240 QDomNodeList( const QDomNodeList& ); 00241 QDomNodeList& operator= ( const QDomNodeList& ); 00242 bool operator== ( const QDomNodeList& ) const; 00243 bool operator!= ( const QDomNodeList& ) const; 00244 virtual ~QDomNodeList(); 00245 00246 // DOM functions 00247 virtual QDomNode item( int index ) const; 00248 00249 // DOM read only attributes 00250 virtual uint length() const; 00251 uint count() const { return length(); } // Qt API consitancy 00252 00253 //### AbanQ Optimization Hack 00254 void * internalImpl() const { return impl; } 00255 //### 00256 00257 private: 00258 QDomNodeListPrivate* impl; 00259 QDomNodeList( QDomNodeListPrivate* ); 00260 00261 friend class QDomNode; 00262 friend class QDomElement; 00263 friend class QDomDocument; 00264 }; 00265 00266 class QM_EXPORT_DOM QDomDocumentType : public QDomNode 00267 { 00268 public: 00269 QDomDocumentType(); 00270 QDomDocumentType( const QDomDocumentType& x ); 00271 QDomDocumentType& operator= ( const QDomDocumentType& ); 00272 ~QDomDocumentType(); 00273 00274 // DOM read only attributes 00275 virtual QString name() const; 00276 virtual QDomNamedNodeMap entities() const; 00277 virtual QDomNamedNodeMap notations() const; 00278 virtual QString publicId() const; 00279 virtual QString systemId() const; 00280 virtual QString internalSubset() const; 00281 00282 // Reimplemented from QDomNode 00283 QDomNode::NodeType nodeType() const; 00284 bool isDocumentType() const; 00285 00286 private: 00287 QDomDocumentType( QDomDocumentTypePrivate* ); 00288 00289 friend class QDomImplementation; 00290 friend class QDomDocument; 00291 friend class QDomNode; 00292 }; 00293 00294 class QM_EXPORT_DOM QDomDocument : public QDomNode 00295 { 00296 public: 00297 QDomDocument(); 00298 Q_EXPLICIT QDomDocument( const QString& name ); 00299 Q_EXPLICIT QDomDocument( const QDomDocumentType& doctype ); 00300 QDomDocument( const QDomDocument& x ); 00301 QDomDocument& operator= ( const QDomDocument& ); 00302 ~QDomDocument(); 00303 00304 // DOM functions 00305 QDomElement createElement( const QString& tagName ); 00306 QDomDocumentFragment createDocumentFragment(); 00307 QDomText createTextNode( const QString& data ); 00308 QDomComment createComment( const QString& data ); 00309 QDomCDATASection createCDATASection( const QString& data ); 00310 QDomProcessingInstruction createProcessingInstruction( const QString& target, const QString& data ); 00311 QDomAttr createAttribute( const QString& name ); 00312 QDomEntityReference createEntityReference( const QString& name ); 00313 QDomNodeList elementsByTagName( const QString& tagname ) const; 00314 QDomNode importNode( const QDomNode& importedNode, bool deep ); 00315 QDomElement createElementNS( const QString& nsURI, const QString& qName ); 00316 QDomAttr createAttributeNS( const QString& nsURI, const QString& qName ); 00317 QDomNodeList elementsByTagNameNS( const QString& nsURI, const QString& localName ); 00318 QDomElement elementById( const QString& elementId ); 00319 00320 // DOM read only attributes 00321 QDomDocumentType doctype() const; 00322 QDomImplementation implementation() const; 00323 QDomElement documentElement() const; 00324 00325 // Qt extensions 00326 bool setContent( const QCString& text, bool namespaceProcessing, QString *errorMsg=0, int *errorLine=0, int *errorColumn=0 ); 00327 bool setContent( const QByteArray& text, bool namespaceProcessing, QString *errorMsg=0, int *errorLine=0, int *errorColumn=0 ); 00328 bool setContent( const QString& text, bool namespaceProcessing, QString *errorMsg=0, int *errorLine=0, int *errorColumn=0 ); 00329 bool setContent( QIODevice* dev, bool namespaceProcessing, QString *errorMsg=0, int *errorLine=0, int *errorColumn=0 ); 00330 bool setContent( const QCString& text, QString *errorMsg=0, int *errorLine=0, int *errorColumn=0 ); 00331 bool setContent( const QByteArray& text, QString *errorMsg=0, int *errorLine=0, int *errorColumn=0 ); 00332 bool setContent( const QString& text, QString *errorMsg=0, int *errorLine=0, int *errorColumn=0 ); 00333 bool setContent( QIODevice* dev, QString *errorMsg=0, int *errorLine=0, int *errorColumn=0 ); 00334 00335 bool setContent( QXmlInputSource *source, QXmlReader *reader, QString *errorMsg=0, int *errorLine=0, int *errorColumn=0 ); 00336 00337 // Reimplemented from QDomNode 00338 QDomNode::NodeType nodeType() const; 00339 bool isDocument() const; 00340 00341 // Qt extensions 00342 QString toString() const; // ### Qt 4: merge the two overloads 00343 QString toString( int ) const; 00344 QCString toCString() const; // ### Qt 4: merge the two overloads 00345 QCString toCString( int ) const; 00346 00347 private: 00348 QDomDocument( QDomDocumentPrivate* ); 00349 00350 friend class QDomNode; 00351 }; 00352 00353 class QM_EXPORT_DOM QDomNamedNodeMap 00354 { 00355 public: 00356 QDomNamedNodeMap(); 00357 QDomNamedNodeMap( const QDomNamedNodeMap& ); 00358 QDomNamedNodeMap& operator= ( const QDomNamedNodeMap& ); 00359 bool operator== ( const QDomNamedNodeMap& ) const; 00360 bool operator!= ( const QDomNamedNodeMap& ) const; 00361 ~QDomNamedNodeMap(); 00362 00363 // DOM functions 00364 QDomNode namedItem( const QString& name ) const; 00365 QDomNode setNamedItem( const QDomNode& newNode ); 00366 QDomNode removeNamedItem( const QString& name ); 00367 QDomNode item( int index ) const; 00368 QDomNode namedItemNS( const QString& nsURI, const QString& localName ) const; 00369 QDomNode setNamedItemNS( const QDomNode& newNode ); 00370 QDomNode removeNamedItemNS( const QString& nsURI, const QString& localName ); 00371 00372 // DOM read only attributes 00373 uint length() const; 00374 uint count() const { return length(); } // Qt API consitancy 00375 00376 // Qt extension 00377 bool contains( const QString& name ) const; 00378 00379 private: 00380 QDomNamedNodeMapPrivate* impl; 00381 QDomNamedNodeMap( QDomNamedNodeMapPrivate* ); 00382 00383 friend class QDomNode; 00384 friend class QDomDocumentType; 00385 friend class QDomElement; 00386 }; 00387 00388 class QM_EXPORT_DOM QDomDocumentFragment : public QDomNode 00389 { 00390 public: 00391 QDomDocumentFragment(); 00392 QDomDocumentFragment( const QDomDocumentFragment& x ); 00393 QDomDocumentFragment& operator= ( const QDomDocumentFragment& ); 00394 ~QDomDocumentFragment(); 00395 00396 // Reimplemented from QDomNode 00397 QDomNode::NodeType nodeType() const; 00398 bool isDocumentFragment() const; 00399 00400 private: 00401 QDomDocumentFragment( QDomDocumentFragmentPrivate* ); 00402 00403 friend class QDomDocument; 00404 friend class QDomNode; 00405 }; 00406 00407 class QM_EXPORT_DOM QDomCharacterData : public QDomNode 00408 { 00409 public: 00410 QDomCharacterData(); 00411 QDomCharacterData( const QDomCharacterData& x ); 00412 QDomCharacterData& operator= ( const QDomCharacterData& ); 00413 ~QDomCharacterData(); 00414 00415 // DOM functions 00416 virtual QString substringData( unsigned long offset, unsigned long count ); 00417 virtual void appendData( const QString& arg ); 00418 virtual void insertData( unsigned long offset, const QString& arg ); 00419 virtual void deleteData( unsigned long offset, unsigned long count ); 00420 virtual void replaceData( unsigned long offset, unsigned long count, const QString& arg ); 00421 00422 // DOM read only attributes 00423 virtual uint length() const; 00424 00425 // DOM attributes 00426 virtual QString data() const; 00427 virtual void setData( const QString& ); 00428 00429 // Reimplemented from QDomNode 00430 QDomNode::NodeType nodeType() const; 00431 bool isCharacterData() const; 00432 00433 private: 00434 QDomCharacterData( QDomCharacterDataPrivate* ); 00435 00436 friend class QDomDocument; 00437 friend class QDomText; 00438 friend class QDomComment; 00439 friend class QDomNode; 00440 }; 00441 00442 class QM_EXPORT_DOM QDomAttr : public QDomNode 00443 { 00444 public: 00445 QDomAttr(); 00446 QDomAttr( const QDomAttr& x ); 00447 QDomAttr& operator= ( const QDomAttr& ); 00448 ~QDomAttr(); 00449 00450 // DOM read only attributes 00451 virtual QString name() const; 00452 virtual bool specified() const; 00453 virtual QDomElement ownerElement() const; 00454 00455 // DOM attributes 00456 virtual QString value() const; 00457 virtual void setValue( const QString& ); 00458 00459 // Reimplemented from QDomNode 00460 QDomNode::NodeType nodeType() const; 00461 bool isAttr() const; 00462 00463 private: 00464 QDomAttr( QDomAttrPrivate* ); 00465 00466 friend class QDomDocument; 00467 friend class QDomElement; 00468 friend class QDomNode; 00469 }; 00470 00471 class QM_EXPORT_DOM QDomElement : public QDomNode 00472 { 00473 public: 00474 QDomElement(); 00475 QDomElement( const QDomElement& x ); 00476 QDomElement& operator= ( const QDomElement& ); 00477 ~QDomElement(); 00478 00479 // DOM functions 00480 QString attribute( const QString& name, const QString& defValue = QString::null ) const; 00481 void setAttribute( const QString& name, const QString& value ); 00482 void setAttribute( const QString& name, int value ); 00483 void setAttribute( const QString& name, uint value ); 00484 void setAttribute( const QString& name, long value ); 00485 void setAttribute( const QString& name, ulong value ); 00486 void setAttribute( const QString& name, double value ); 00487 void removeAttribute( const QString& name ); 00488 QDomAttr attributeNode( const QString& name); 00489 QDomAttr setAttributeNode( const QDomAttr& newAttr ); 00490 QDomAttr removeAttributeNode( const QDomAttr& oldAttr ); 00491 virtual QDomNodeList elementsByTagName( const QString& tagname ) const; 00492 bool hasAttribute( const QString& name ) const; 00493 00494 QString attributeNS( const QString nsURI, const QString& localName, const QString& defValue ) const; 00495 void setAttributeNS( const QString nsURI, const QString& qName, const QString& value ); 00496 void setAttributeNS( const QString nsURI, const QString& qName, int value ); 00497 void setAttributeNS( const QString nsURI, const QString& qName, uint value ); 00498 void setAttributeNS( const QString nsURI, const QString& qName, long value ); 00499 void setAttributeNS( const QString nsURI, const QString& qName, ulong value ); 00500 void setAttributeNS( const QString nsURI, const QString& qName, double value ); 00501 void removeAttributeNS( const QString& nsURI, const QString& localName ); 00502 QDomAttr attributeNodeNS( const QString& nsURI, const QString& localName ); 00503 QDomAttr setAttributeNodeNS( const QDomAttr& newAttr ); 00504 virtual QDomNodeList elementsByTagNameNS( const QString& nsURI, const QString& localName ) const; 00505 bool hasAttributeNS( const QString& nsURI, const QString& localName ) const; 00506 00507 // DOM read only attributes 00508 QString tagName() const; 00509 void setTagName( const QString& name ); // Qt extension 00510 00511 // Reimplemented from QDomNode 00512 QDomNamedNodeMap attributes() const; 00513 QDomNode::NodeType nodeType() const; 00514 bool isElement() const; 00515 00516 QString text() const; 00517 00518 private: 00519 QDomElement( QDomElementPrivate* ); 00520 00521 friend class QDomDocument; 00522 friend class QDomNode; 00523 friend class QDomAttr; 00524 }; 00525 00526 class QM_EXPORT_DOM QDomText : public QDomCharacterData 00527 { 00528 public: 00529 QDomText(); 00530 QDomText( const QDomText& x ); 00531 QDomText& operator= ( const QDomText& ); 00532 ~QDomText(); 00533 00534 // DOM functions 00535 QDomText splitText( int offset ); 00536 00537 // Reimplemented from QDomNode 00538 QDomNode::NodeType nodeType() const; 00539 bool isText() const; 00540 00541 private: 00542 QDomText( QDomTextPrivate* ); 00543 00544 friend class QDomCDATASection; 00545 friend class QDomDocument; 00546 friend class QDomNode; 00547 }; 00548 00549 class QM_EXPORT_DOM QDomComment : public QDomCharacterData 00550 { 00551 public: 00552 QDomComment(); 00553 QDomComment( const QDomComment& x ); 00554 QDomComment& operator= ( const QDomComment& ); 00555 ~QDomComment(); 00556 00557 // Reimplemented from QDomNode 00558 QDomNode::NodeType nodeType() const; 00559 bool isComment() const; 00560 00561 private: 00562 QDomComment( QDomCommentPrivate* ); 00563 00564 friend class QDomDocument; 00565 friend class QDomNode; 00566 }; 00567 00568 class QM_EXPORT_DOM QDomCDATASection : public QDomText 00569 { 00570 public: 00571 QDomCDATASection(); 00572 QDomCDATASection( const QDomCDATASection& x ); 00573 QDomCDATASection& operator= ( const QDomCDATASection& ); 00574 ~QDomCDATASection(); 00575 00576 // Reimplemented from QDomNode 00577 QDomNode::NodeType nodeType() const; 00578 bool isCDATASection() const; 00579 00580 private: 00581 QDomCDATASection( QDomCDATASectionPrivate* ); 00582 00583 friend class QDomDocument; 00584 friend class QDomNode; 00585 }; 00586 00587 class QM_EXPORT_DOM QDomNotation : public QDomNode 00588 { 00589 public: 00590 QDomNotation(); 00591 QDomNotation( const QDomNotation& x ); 00592 QDomNotation& operator= ( const QDomNotation& ); 00593 ~QDomNotation(); 00594 00595 // DOM read only attributes 00596 QString publicId() const; 00597 QString systemId() const; 00598 00599 // Reimplemented from QDomNode 00600 QDomNode::NodeType nodeType() const; 00601 bool isNotation() const; 00602 00603 private: 00604 QDomNotation( QDomNotationPrivate* ); 00605 00606 friend class QDomDocument; 00607 friend class QDomNode; 00608 }; 00609 00610 class QM_EXPORT_DOM QDomEntity : public QDomNode 00611 { 00612 public: 00613 QDomEntity(); 00614 QDomEntity( const QDomEntity& x ); 00615 QDomEntity& operator= ( const QDomEntity& ); 00616 ~QDomEntity(); 00617 00618 // DOM read only attributes 00619 virtual QString publicId() const; 00620 virtual QString systemId() const; 00621 virtual QString notationName() const; 00622 00623 // Reimplemented from QDomNode 00624 QDomNode::NodeType nodeType() const; 00625 bool isEntity() const; 00626 00627 private: 00628 QDomEntity( QDomEntityPrivate* ); 00629 00630 friend class QDomNode; 00631 }; 00632 00633 class QM_EXPORT_DOM QDomEntityReference : public QDomNode 00634 { 00635 public: 00636 QDomEntityReference(); 00637 QDomEntityReference( const QDomEntityReference& x ); 00638 QDomEntityReference& operator= ( const QDomEntityReference& ); 00639 ~QDomEntityReference(); 00640 00641 // Reimplemented from QDomNode 00642 QDomNode::NodeType nodeType() const; 00643 bool isEntityReference() const; 00644 00645 private: 00646 QDomEntityReference( QDomEntityReferencePrivate* ); 00647 00648 friend class QDomDocument; 00649 friend class QDomNode; 00650 }; 00651 00652 class QM_EXPORT_DOM QDomProcessingInstruction : public QDomNode 00653 { 00654 public: 00655 QDomProcessingInstruction(); 00656 QDomProcessingInstruction( const QDomProcessingInstruction& x ); 00657 QDomProcessingInstruction& operator= ( const QDomProcessingInstruction& ); 00658 ~QDomProcessingInstruction(); 00659 00660 // DOM read only attributes 00661 virtual QString target() const; 00662 00663 // DOM attributes 00664 virtual QString data() const; 00665 virtual void setData( const QString& d ); 00666 00667 // Reimplemented from QDomNode 00668 QDomNode::NodeType nodeType() const; 00669 bool isProcessingInstruction() const; 00670 00671 private: 00672 QDomProcessingInstruction( QDomProcessingInstructionPrivate* ); 00673 00674 friend class QDomDocument; 00675 friend class QDomNode; 00676 }; 00677 00678 00679 QM_EXPORT_DOM QTextStream& operator<<( QTextStream&, const QDomNode& ); 00680 00681 #endif //QT_NO_DOM 00682 #endif // QDOM_H