2
* parser.h - parse an XMPP "document"
3
* Copyright (C) 2003 Justin Karneges
5
* This library is free software; you can redistribute it and/or
6
* modify it under the terms of the GNU Lesser General Public
7
* License as published by the Free Software Foundation; either
8
* version 2.1 of the License, or (at your option) any later version.
10
* This library is distributed in the hope that it will be useful,
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
* Lesser General Public License for more details.
15
* You should have received a copy of the GNU Lesser General Public
16
* License along with this library; if not, write to the Free Software
17
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
38
enum Type { DocumentOpen, DocumentClose, Element, Error };
41
Event & operator=(const Event &);
48
QString nsprefix(const QString &s=QString::null) const;
50
// for document open / close
51
QString namespaceURI() const;
52
QString localName() const;
53
QString qName() const;
54
QXmlAttributes atts() const;
57
QDomElement element() const;
60
QString actualString() const;
63
void setDocumentOpen(const QString &namespaceURI, const QString &localName, const QString &qName, const QXmlAttributes &atts, const QStringList &nsnames, const QStringList &nsvalues);
64
void setDocumentClose(const QString &namespaceURI, const QString &localName, const QString &qName);
65
void setElement(const QDomElement &elem);
67
void setActualString(const QString &);
75
void appendData(const QByteArray &a);
77
QByteArray unprocessed() const;
78
QString encoding() const;