public class OperationSetGenericNotificationsJabberImpl extends java.lang.Object implements OperationSetGenericNotifications, org.jivesoftware.smack.PacketListener
Constructor and Description |
---|
OperationSetGenericNotificationsJabberImpl(ProtocolProviderServiceJabberImpl provider)
Creates an instance of this operation set.
|
Modifier and Type | Method and Description |
---|---|
void |
addGenericEventListener(java.lang.String eventName,
GenericEventListener listener)
Registers a GenericEventListener with this
operation set so that it gets notifications for new
event notifications.
|
void |
notifyForEvent(Contact contact,
java.lang.String eventName,
java.lang.String eventValue)
Generates new event notification.
|
void |
notifyForEvent(java.lang.String jid,
java.lang.String eventName,
java.lang.String eventValue)
Generates new generic event notification and send it to the
supplied contact.
|
void |
notifyForEvent(java.lang.String jid,
java.lang.String eventName,
java.lang.String eventValue,
java.lang.String source)
Generates new generic event notification and send it to the
supplied contact.
|
void |
processPacket(org.jivesoftware.smack.packet.Packet packet)
Process the next packet sent to this packet listener.
|
void |
removeGenericEventListener(java.lang.String eventName,
GenericEventListener listener)
Unregisters listener so that it won't receive any further
notifications upon new event notifications.
|
OperationSetGenericNotificationsJabberImpl(ProtocolProviderServiceJabberImpl provider)
provider
- a reference to the ProtocolProviderServiceImpl
that created us and that we'll use for retrieving the underlying aim
connection.public void notifyForEvent(Contact contact, java.lang.String eventName, java.lang.String eventValue)
notifyForEvent
in interface OperationSetGenericNotifications
contact
- the contact to receive the notification.eventName
- the event name of the notification.eventValue
- the event value of the notification.public void notifyForEvent(java.lang.String jid, java.lang.String eventName, java.lang.String eventValue)
notifyForEvent
in interface OperationSetGenericNotifications
jid
- the contact jid which will receive the event notification.eventName
- the event name of the notification.eventValue
- the event value of the notification.public void notifyForEvent(java.lang.String jid, java.lang.String eventName, java.lang.String eventValue, java.lang.String source)
notifyForEvent
in interface OperationSetGenericNotifications
jid
- the contact jid which will receive the event notification.eventName
- the event name of the notification.eventValue
- the event value of the notification.source
- the source that will be reported in the event.public void addGenericEventListener(java.lang.String eventName, GenericEventListener listener)
addGenericEventListener
in interface OperationSetGenericNotifications
eventName
- register the listener for certain event name.listener
- the GenericEventListener
to register.public void removeGenericEventListener(java.lang.String eventName, GenericEventListener listener)
removeGenericEventListener
in interface OperationSetGenericNotifications
eventName
- unregister the listener for certain event name.listener
- the GenericEventListener
to unregister.public void processPacket(org.jivesoftware.smack.packet.Packet packet)
processPacket
in interface org.jivesoftware.smack.PacketListener
packet
- the packet to process.
Jitsi, the OpenSource Java VoIP and Instant Messaging client.
Distributable under Apache license.