Sun Java System Instant Messaging 7 2005Q1 Administration Guide |
Appendix C
Instant Messaging APIsThis chapter describes the APIs used by Instant Messaging.
Instant Messaging APIs OverviewInstant Messaging provides Java APIs which can be used to develop extension or integration modules. Detailed documentation of these APIs are provided with the installed Instant Messenger component, in the form of HTML files generated by Javadocs. The Javadoc files are installed in the im_svr_base/html/apidocs/ directory. To view the API documentation, point your browser to imcodebase/apidocs where the codebase is the Instant Messenger resources codebase.
The following are the Instant Messaging APIs:
Instant Messaging Service APIThe Instant Messaging API is used by the applications located on the same host or in the remote host to access Instant Messaging services, such as Presence, Conference, Notification, Polls and News channels.
The Instant Messaging Service API can be used for:
Messenger BeansA Messenger bean is a dynamically loaded module used to extend the messenger functionality. Messenger beans can add action listeners, such as buttons and menu items, and item listeners, such as check boxes and toggle buttons in the existing Instant Messenger window. The item listeners are invoked when an end-user input is received and bean-specific actions are based on the end-user input. Beans have the ability to add their own settings panel and save bean-specific properties on the server. Beans can be notified of any event received by the Instant Messenger. for example, a new alert message.
The applications that use Messenger Beans are:
Service Provider InterfacesThe Service Provider Interface APIs provide the ability to extend the Instant Messaging server functionality. The Service Provider Interface is composed of the following independent APIs:
Archive Provider API
An Archive Provider is a software module usually providing integration with the archive or auditing system. Each configured Archive Provider is invoked for each server process.
The Archive Provider is invoked for the following server processes:
- When a instant message is sent. The Instant Messages, such as alert, poll, chat, news or conference.
- During an authentication event, such as login or logout.
- When there is a change in the presence status.
- During a subscription event. For example, when someone joins or leaves a conference, or subscribes or unsubscribes to a news channel.
The applications that use the Archive Provider API are as follows:
- Instant Messaging Archive
The default Instant Messaging archive in Instant Messaging is based on the Archive Provider API. For more information on Instant Messaging Archive, see Managing The Instant Messaging Archive.
- The application that records the usage statistics for sizing purposes
Message Conversion API
A Message Converter is invoked for every message or each message part going through the server. The Message Converter may leave the message part intact or modify or remove the message part. The text parts are processed as Java String Objects. The Message Converter processes other attachment as a stream of bytes and returns a potentially different stream of bytes, or nothing at all if the attachment is to be removed.
The applications that uses Message Conversion API are:
Authentication Provider APIThe Authentication Provider API provides ability to deploy Instant Messaging in environments that are not using Access Manager password-based or token-based authentication service. This API is invoked whenever an end user requests authentication, and it can be used in conjunction with the LDAP authentication.
Single Sign-on (SSO) with Access Manager is performed using the Authentication Provider API. This API can also be used to integrate with other authentication systems.