QXmppPubSubEvent Class
The QXmppPubSubEvent class represents a PubSub event notification as defined by XEP-0060: Publish-Subscribe. More...
| Header: | #include <QXmppPubSubEvent.h> |
| Since: | QXmpp 1.5 |
| Inherits: | QXmppPubSubEventBase |
- List of all members, including inherited members
- QXmppPubSubEvent is part of Stanzas.
Public Functions
Static Public Members
| bool | isPubSubEvent(const QDomElement &element) |
Detailed Description
This class has a template parameter that can be used to define the type of the contained items.
You can use QXmppPubSubEvent::isPubSubItem() to check whether an DOM element is a <message/> with a PubSub event notification. If you set a special type as a template parameter, validity of the items will also be checked. To check for an event notification with items from XEP-0118: User Tune for example, you could use the following:
QXmppPubSubEvent<QXmppTuneItem>::isPubSubEvent(element);
Member Function Documentation
[static] bool QXmppPubSubEvent::isPubSubEvent(const QDomElement &element)
Returns whether the element element is a valid QXmppPubSubEvent and contains only valid items of type T.
QList<T> QXmppPubSubEvent::items() const
Returns the PubSub items of the event.
See also setItems().
void QXmppPubSubEvent::setItems(const QList<T> &items)
Sets the PubSub items of the event.
See also items().