equal
deleted
inserted
replaced
558 PrematureEndOfDocumentError, it means the XML has been well-formed |
558 PrematureEndOfDocumentError, it means the XML has been well-formed |
559 so far, but a complete XML document has not been parsed. The next |
559 so far, but a complete XML document has not been parsed. The next |
560 chunk of XML can be added with addData(), if the XML is being read |
560 chunk of XML can be added with addData(), if the XML is being read |
561 from a QByteArray, or by waiting for more data to arrive if the |
561 from a QByteArray, or by waiting for more data to arrive if the |
562 XML is being read from a QIODevice. Either way, atEnd() will |
562 XML is being read from a QIODevice. Either way, atEnd() will |
563 return false once more adata is available. |
563 return false once more data is available. |
564 |
564 |
565 \sa hasError(), error(), device(), QIODevice::atEnd() |
565 \sa hasError(), error(), device(), QIODevice::atEnd() |
566 */ |
566 */ |
567 bool QXmlStreamReader::atEnd() const |
567 bool QXmlStreamReader::atEnd() const |
568 { |
568 { |
3714 */ |
3714 */ |
3715 void QXmlStreamWriter::writeProcessingInstruction(const QString &target, const QString &data) |
3715 void QXmlStreamWriter::writeProcessingInstruction(const QString &target, const QString &data) |
3716 { |
3716 { |
3717 Q_D(QXmlStreamWriter); |
3717 Q_D(QXmlStreamWriter); |
3718 Q_ASSERT(!data.contains(QLatin1String("?>"))); |
3718 Q_ASSERT(!data.contains(QLatin1String("?>"))); |
3719 d->finishStartElement(); |
3719 if (!d->finishStartElement(false) && d->autoFormatting) |
|
3720 d->indent(d->tagStack.size()); |
3720 d->write("<?"); |
3721 d->write("<?"); |
3721 d->write(target); |
3722 d->write(target); |
3722 if (!data.isNull()) { |
3723 if (!data.isNull()) { |
3723 d->write(" "); |
3724 d->write(" "); |
3724 d->write(data); |
3725 d->write(data); |