I’m developing a PEP extension , and so far I’ve managed to publish geoloc and mood events correctly. However, I’m not quite clear as to how to process event notifications. Here is what I send to the server … :
<iq id=“geoloc” from=“user1@satriani/Smack” type=“set”>
<publish node=“http://jabber.org/protocol/geoloc” >
<geoloc xmlns=“http://jabber.org/protocol/geoloc” xml:lang=“en”>
and here is what the server responds :
+<iq type=“result” id=“geoloc” to=“user1@satriani/satriani” />
<message from=“user1@satriani” to=“user1@satriani” id=“http://jabber.org/protocol/geoloc__user1@satriani__R04sI” >
<items node=“http://jabber.org/protocol/geoloc” >
<item id=“PxlNHOh1VPD6TGz” >
<geoloc xmlns=“http://jabber.org/protocol/geoloc” xml:lang=“en” >
I’d grateful if anyone could shed some light .
many thanks in advance.
me again ! I have created and registered a PubSubEventProvider, which parses any messages that contain PubSub events, specifically PEP events at the moment. However, I am finding myself in a bit of fix as I I don’t really want PubSubEventProvider to deal with all PEP events, or all PubSub events for that matter, but rather I’d like to use a provider for each single PEP event. In so doing, i’d be able to catch each single PEP event directy without having to find out unorthodoxically the type of the event just caght. …
To make matters clearer. At the present time, PubSubEventProvider parses all PubSub all notifications/events ( only theoretically, because I’m only interested in PEP at the moment ). PacketExtension parseExtension(XmlPullParser parser) returns an object of type PubSubEvent, which refers to an object of type Items, which in turns refers to a series of objects of type Item. Each Item contains a PEP notification. Basically the information I’m really interested in is really buried deep within the PubSubEvent object, which makes it somewhat awkward to deal with. Is there a way for PacketExtension parseExtension(XmlPullParser parser) to return a PEP event/notification rather than a generic PubSubEvent ? … I’d love that so much