Openfire 3.4.3 Javadoc

org.jivesoftware.openfire.handler
Class PresenceSubscribeHandler

java.lang.Object
  extended by org.jivesoftware.openfire.container.BasicModule
      extended by org.jivesoftware.openfire.handler.PresenceSubscribeHandler
All Implemented Interfaces:
ChannelHandler, Module

public class PresenceSubscribeHandler
extends BasicModule
implements ChannelHandler

Implements the presence protocol. Clients use this protocol to update presence and roster information.

The handler must properly detect the presence type, update the user's roster, and inform presence subscribers of the session's updated presence status. Presence serves many purposes in Jabber so this handler will likely be the most complex of all handlers in the server.

There are four basic types of presence updates:

Warning

There should be a way of determining whether a session has authorization to access this feature. I'm not sure it is a good idea to do authorization in each handler. It would be nice if the framework could assert authorization policies across channels.

Author:
Iain Shigeoka

Constructor Summary
PresenceSubscribeHandler()
           
 
Method Summary
 void initialize(XMPPServer server)
          Initializes the basic module.
 void process(Packet xmppPacket)
          Process an XMPP packet.
 
Methods inherited from class org.jivesoftware.openfire.container.BasicModule
destroy, getName, start, stop
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PresenceSubscribeHandler

public PresenceSubscribeHandler()
Method Detail

process

public void process(Packet xmppPacket)
             throws PacketException
Description copied from interface: ChannelHandler
Process an XMPP packet.

Specified by:
process in interface ChannelHandler
Parameters:
xmppPacket - a packet to process.
Throws:
PacketException - thrown if the packet is malformed (results in the sender's session being shutdown).

initialize

public void initialize(XMPPServer server)
Description copied from class: BasicModule

Initializes the basic module.

Inheriting classes that choose to override this method MUST call this initialize() method before accessing BasicModule resources.

Specified by:
initialize in interface Module
Overrides:
initialize in class BasicModule
Parameters:
server - the server hosting this module.

Openfire 3.4.3 Javadoc

Copyright © 2003-2007 Jive Software.