org.jivesoftware.openfire.container
Interface Module
- All Known Subinterfaces:
- FileTransferManager
- All Known Implementing Classes:
- AdHocCommandHandler, AuditManagerImpl, BasicModule, ConnectionManagerImpl, DefaultFileTransferManager, FileTransferProxy, FlashCrossDomainHandler, InternalComponentManager, IQAuthHandler, IQBindHandler, IQDiscoInfoHandler, IQDiscoItemsHandler, IQHandler, IQLastActivityHandler, IQOfflineMessagesHandler, IQPEPHandler, IQPEPOwnerHandler, IQPrivacyHandler, IQPrivateHandler, IQRegisterHandler, IQRosterHandler, IQRouter, IQSessionEstablishmentHandler, IQSharedGroupHandler, IQTimeHandler, IQvCardHandler, IQVersionHandler, MediaProxyService, MessageRouter, MulticastDNSService, MulticastRouter, MultiUserChatServerImpl, OfflineMessageStore, OfflineMessageStrategy, PacketDelivererImpl, PacketRouterImpl, PacketTransporterImpl, PresenceManagerImpl, PresenceRouter, PresenceSubscribeHandler, PresenceUpdateHandler, PrivateStorage, PubSubModule, RosterManager, RoutingTableImpl, SessionManager, STUNService, TransportHandler, UpdateManager, VCardManager
public interface Module
Logical, server-managed entities must implement this interface. A module
represents an operational unit and may contain zero or more services
and rely on zero or more services that may be hosted by the container.
In order to be hosted in the Jive server container, all modules must:
- Implement the Module interface
- Have a public no-arg constructor
The Jive container will run all modules through a simple lifecycle:
constructor -> initialize() -> start() -> stop() -> destroy() -> finalizer
|<-----------------------| ^
| |
V----------------------------------->
The Module interface is intended to provide the simplest mechanism
for creating, deploying, and managing server modules.
- Author:
- Iain Shigeoka
Method Summary |
void |
destroy()
Module should free all resources and prepare for deallocation. |
String |
getName()
Returns the name of the module for display in administration interfaces. |
void |
initialize(XMPPServer server)
Initialize the module with the container. |
void |
start()
Start the module (must return quickly). |
void |
stop()
Stop the module. |
getName
String getName()
- Returns the name of the module for display in administration interfaces.
- Returns:
- The name of the module.
initialize
void initialize(XMPPServer server)
- Initialize the module with the container.
Modules may be initialized and never started, so modules
should be prepared for a call to destroy() to follow initialize().
- Parameters:
server
- the server hosting this module.
start
void start()
- Start the module (must return quickly). Any long running
operations should spawn a thread and allow the method to return
immediately.
stop
void stop()
- Stop the module. The module should attempt to free up threads
and prepare for either another call to initialize (reconfigure the module)
or for destruction.
destroy
void destroy()
- Module should free all resources and prepare for deallocation.
Copyright © 2003-2007 Jive Software.