Lotus Sametime has been built on Eclipse-based Lotus Expeditor (formerly called IBM WebSphere® Everyplace® Deployment) since release 7.5. Lotus Sametime leverages the Eclipse plug-in framework to provide extensibility features that go beyond those available in previous releases. In fact, many plug-ins that expand the functionality of Lotus Sametime are shipped with the product. With the Lotus Sametime SDK or Lotus Expeditor toolkit, vendors can build additional plug-ins for Lotus Sametime.
Lotus Expeditor is a universal desktop client integration framework; it helps you integrate a wide variety of client and server applications in business mashups. It is an Eclipse-based Java⢠Enterprise Edition (JavaEE) client application development and runtime platform. IBM Lotus Expeditor also provides the core client technology for the latest versions of IBM Lotus Notes®, Lotus Sametime, and IBM Lotus Symphonyâ¢.
The Lotus Expeditor toolkit gives you the capability to develop Java Enterprise Edition and Eclipse applications for Lotus Expeditor, Lotus Sametime, Lotus Notes, and Lotus Symphony. The toolkit lets you select the target client platform, and then it automatically configures the development environment with the features needed to develop applications for the selected platform. For example, when you develop a plug-in for Lotus Sametime, you can select the Embedded Sametime target.
The procedure described in this article is intended for Java developers who are familiar with Eclipse plug-in development. It requires that the Lotus Expeditor toolkit 6.1.2 be installed on one of these integrated development environments (IDEs):
- IBM Rational® Application Developer 7.0.0.4
- IBM Rational Software Architect 7.0.0.4
- Eclipse 3.2.2 and Web Tools Project 1.5.4
- IBM WebSphere Application Server Toolkit 6.1.1.4
For a simple installation and configuration guide of the Lotus Expeditor toolkit 6.1.2, refer to the developerWorks® Lotus article, "Getting started with the IBM Lotus Expeditor Toolkit V6.1.1." In the remainder of this article, we assume that the IDE used is Rational Application Developer and that the Lotus Expeditor toolkit 6.1.2 is installed.
Create a plug-in project or client services project to extend Lotus Sametime
You need to create only a plug-in project to extend Lotus Sametime. Of course, you also could create a client services project to extend Lotus Sametime, as shown in figure 1.
Figure 1. Creating a client services project in the New Project wizard

The client services project extends the plug-in project by letting you configure a target and dependencies in the New Project wizard as shown in figure 2. To develop plug-ins for Lotus Sametime, you can select the option Default with Embedded Sametime Target in the Target field. The Lotus Expeditor toolkit includes an embedded Lotus Sametime runtime for use in the development phase; with it, you can run or debug a plug-in application in Lotus Sametime from Rational Application Developer without installing Lotus Sametime separately. To reiterate, you do not have to create a client services project to extend Lotus Sametime; a standard plug-in project is sufficient.
Figure 2. Configuring the target for the client services project

After you create the plug-in project or client services project, you might want to write code to extend Lotus Sametime, but first you should consider the extension points that Lotus Sametime provides. There are a number of extension points that allow you to integrate your functionality seamlessly into the user interface (UI) of the Lotus Sametime client. With these extension points, you can contribute new actions to the toolbar, the menu bar, the context menu, and the system tray menu; you can also customize the branding of Lotus Sametime and add mini applications to it. Figures 3 and 4, along with figures 6 and 7 and table 1, are extracted from the IBM Redbooks® publication, "Extending Sametime 7.5 Building Plug-ins for Sametime." They show the UI features that can be extended in the contact list window and the chat window.
Figure 3. UI features that can be extended in the contact list window

Figure 4. UI features that can be extended in the chat window

Letâs add an action to the action bar and the message toolbar of the chat window. Follow these steps:
- Open the MANIFEST.MF file with the Plug-in Manifest Editor.
- Select the Extensions tab, and click the Add button.
- Clear the option Show only extension points form the required plug-ins.
- Enter *chat in the Extension Point filter field to filter out extension points, and then select the extension point com.ibm.collaboration.realtime.chatwindow.chatWindow. See figure 5.
- Click Finish.
Figure 5. Add the chatAction extension point

Eclipse might prompt you to add the plug-in com.ibm.collaboration.realtime.chatwindow to the list of plug-in dependencies. If it does, click Yes and switch to the Dependencies tab to see that the plug-in com.ibm.collaboration.realtime.chatwindow is added to the Required Plug-ins list.
So far, you added the chatAction extension to your plug-in project.
Next, you need to set up the extension point to add concrete action. Right-click the newly added extension, and select New - chatAction in the context menu. The extension element details display. Table 1, also extracted from the IBM Redbooks publication, Extending Sametime 7.5 Building Plug-ins for Sametime, lists the most important fields of the chatAction extension.
Table 1. The important fields of the chatAction extension
| Property name | Meaning |
|---|---|
| id | The unique identity of the chat action. |
| class | The class name of the handler of the chat action. |
| type | The placement of the chat action; it can be placed in the action bar and message toolbar of the chat window.
|
| displayName | The name of the chat action.
|
| image | Works only when the chat action is added to the action bar or the message toolbar. If the image is specified, it presents the chat action as the specified image in the action bar or the message toolbar; if it is not defined, the text specified by the property displayName is used to present the chat action. |
| path | Controls the location of the chat action in the action bar or message toolbar. See figures 6 and Figure 7 to check valid values if the type is buddy or format; if the type is another value, the property does not work. |
| menubarPath | Controls the location of the chat action in the menu bar. You can add the chat action in the main menus File, Edit, View, Tools, and Help; valid values for the property are listed in table 2. |
| showsFor | Specifies whether the chat action is enabled for a one-to-one chat (single), multiparty chat (multi), or both. |
Table 2. Values for the menubarPath property
| File | Edit | View | Tools | Help |
|---|---|---|---|---|
| file/open file/save file/print.group file/preferences file/additions file/fileEnd | edit/editStart edit/additions edit/editEnd | view/viewStart view/additions view/viewEnd | tools/additionsTop tools/additionsMiddle tools/additions tools/actions tools/send/additions tools/insertMenu tools/insertTop tools/insert/top tools/toolsEnd | help/helpStart help/helpEnd |
Figure 6. Valid values for path property if the type is buddy

Figure 7. Valid values for the path property if the type is format

You add the action to the action bar of the chat window, so you set up the properties as shown in figure 8.
Enter the following details in the fields of the Extension Elements Details window:
- In the id field, enter test.sametime.chatAction1.
- In the class field, browse to select test.sametime.ChatActionDelegate1.
- In the type field, select buddy.
- In the displayName field, enter Hello World.
- In the tooltipText field, enter Hello World.
- In the image field, browse to select icons/Open.png.
- In the path field, enter buddy/start.
- In the menubarPath field, enter tools/additionsTop.
- In the showsFor field, select both.
Figure 8. chatAction Extension Element Details window

After you set up the chatAction extension, the plugin.xml file is updated by Rational Application Developer. Listing 1 shows the content of the plugin.xml file.
Listing 1. plugin.xml
<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.2"?>
<plugin>
<extension
point="com.ibm.collaboration.realtime.chatwindow.chatAction">
<chatAction
class="test.sametime.ChatActionDelegate1"
displayName="Hello World"
id="test.sametime.chatAction1"
image="icons/Open.png"
menubarPath="tools/additionsTop"
path="buddy/start"
showsFor="both"
tooltipText="Hello World"
type="buddy"/>
</extension>
</plugin>
|
Finally, you need to implement the chat action handler. Follow these steps:
- Click the class link to create the class file for this extension.
- chatAction wants the class to extend the ChatWindowAction class, so remove the interface suggested by the wizard and add com.ibm.collaboration.realtime.chat.actions.ChatWindowAction as the Superclass.
- Clear the Inherited abstract methods option because you need to implement only one method for your sample application.
- Add a public run() method to call the JFace MessageDialog window, as shown in listing 2.
Listing 2. run() method calling the JFace MessageDialog window
public class ChatActionDelegate1 extends ChatWindowAction {
public void run() {
String title = "Hello, title";
String message = "Hello, world";
MessageDialog.openInformation(null, title, message);
}
}
|
Here you complete the Lotus Sametime plug-in; you need to run it in Rational Application Developer to see the result.
Run and debug the client services project
Follow these steps to run and debug the client services project:
- Click Run - Run, and the Run window displays.
- Double-click the Client Services node to create a new launch configuration, and name it SametimeTest.
- Select the Target tab, and select Default with Embedded Sametime Target as the target.
Because the contact list window of embedded Lotus Sametime docks on the sidebar of Lotus Expeditor (note that the sidebar is not visible if no perspective is opened), you must have a perspective opened to show the sidebar and then to open the contact list window of the Embedded Sametime.
To open a perspective, you can create a simple perspective and add it to the Open menu of Lotus Expeditor, or you can leverage other plug-in applications that define perspectives. The sample feature Order Entry Sample defines perspectives and adds a perspective to the Open menu of Lotus Expeditor as shown in figure 9.
Figure 9. Create a new launch configuration to run

Next, select the Plug-ins tab, select your sample plug-in under Workspace Plug-ins, and click the Add Required Plug-ins button. This sequence adds depended plug-ins automatically. Next, click Run. Wait until the Lotus Expeditor runtime is started, then click the Open button and click Order Entry Web Sample. The relational perspective is opened, and the sidebar displays; you can find the Embedded Sametime icon at the top of sidebar as shown in figure 10.
Figure 10. Embedded Sametime icon in the sidebar

When you click the Embedded Sametime icon, the contact list window displays in the sidebar. Log into a Lotus Sametime server with your account, and double-click any contact. The chat window displays, where you can find the newly added action icon at the beginning of the action bar (because you set buddy/start in the property Path as shown in figure 8). You can also find the newly added menu "Hello World" in the main menu Tools (because you set tools/additionsTop in the property menubarPath as shown in figure 8). See figure 11.
Figure 11. Newly added actions in the action bar of the chat window

When you click the newly added action icon or the menu "Hello World," a JFace message window that displays "Hello, world" opens; it indicates that your Lotus Sametime plug-in works correctly.
You can modify the chatAction extension. Change the property type to format, and change the property path to format/end. Then the chat action is added to the message toolbar of the chat window as shown in figure 12. Click the chat action, and the same JFace message window displays.
Figure 12. Newly added actions in the message toolbar of the chat window

You can run your Lotus Sametime plug-in within the Embedded Sametime of the Lotus Expeditor toolkit. You also can set a breakpoint in the code of listing 2; select Run - Debug to open the Debug window. In the node called Client Services, you can see the launch configuration SametimeTest that you created; select it and click Debug. When you click the chat action, the breakpoint should be triggered, and Rational Application Developer toggles to Debug, so you can make full use of the debug facility that Rational Application Developer provides. Refer to the online help content of the Eclipse SDK for more details on how to use the debug facility.
Packaging the Lotus Sametime plug-in for deployment
Before you can deploy the Lotus Sametime plug-in into Lotus Sametime and Lotus Notes, you need to package the plug-in in an update site. Follow these steps:
- Create a new feature project that includes your Lotus Sametime plug-in.
- Create an update site project, open the site.xml file with the site manifest editor, select the Site Map tab, and click the Add Feature button to add the newly created feature project to this update site.
- In the Site Map tab, click the Build button to build this update site. It generates a feature JAR file in the Features folder and a plugin JAR file in the Plug-ins folder.
- Right-click the update site project, select the Export menu, select General - Archive File or General - File System to export this update site to the archive file or the folder that can be installed in Lotus Sametime.
Deploy the plug-in in Lotus Sametime
Deployment can follow two scenarios: stand-alone Lotus Sametime and Embedded Sametime in Lotus Notes.
Launch Lotus Sametime 7.5 or later, and select Tools - Plug-Ins - Install Plug-ins to open the Install/Update wizard to install plug-ins for Lotus Sametime. The remaining steps are same as those used to install features or plug-ins for Eclipse.
Embedded Sametime in Lotus Notes
Since release 8.0.0, Lotus Notes ships with an Embedded Sametime, which leverages the Install/Update wizard of Lotus Notes to install or update plug-ins. Because the Install/Update wizard is not enabled by default in Lotus Notes 8.0.0 and later, you need to add a new line of code:
com.ibm.notes.branding/enable.update.ui=true
to the file <Notes_Home>/framework/rcp/plugin_customization.ini to enable it. After you add this line of code, you can launch Lotus Notes and select File - Application - Install to open the Install/Update wizard, which you can use to install plug-ins for Lotus Notes.
This article shows you how to develop Lotus Sametime plug-ins with the Lotus Expeditor toolkit, and it demonstrates which Lotus Sametime UI features can be extended. It also shows you how to run and debug Lotus Sametime plug-ins in the Embedded Sametime runtime environment shipped in the Lotus Expeditor toolkit, and it shows you how to install plug-ins for Lotus Sametime and Embedded Sametime in Lotus Notes. With the Lotus Expeditor toolkit, you can develop plug-ins for Lotus Sametime more efficiently.
| Name | Size | Download method |
|---|---|---|
| sametimeTest.zip | 4.7KB | HTTP |
Information about download methods
Learn
-
Read the developerWorks Lotus article, "Introducing IBM Lotus Expeditor V6.1.1."
-
Read the developerWorks Lotus article, "Getting started with the IBM Lotus Expeditor Toolkit V6.1.1."
-
Read the developerWorks Lotus article, "Explore Eclipse's embedded Rich Client Platform."
-
Read the developerWorks Lotus article, "Extending IBM Lotus Sametime Connect V7.5."
-
Read the developerWorks Lotus article, "Designing a Google Maps plug-in for IBM Lotus Sametime Connect V7.5."
-
Read the IBM Redbooks publication, "Extending Sametime 7.5 Building Plug-ins for Sametime."
-
Refer to the IBM Lotus Expeditor product page.
-
Refer to the IBM Lotus Sametime product page.
-
Refer to the Eclipse project resource site.
Get products and technologies
-
Download a trial version of the IBM Lotus Expeditor toolkit V6.1.2.
-
Download a trial version of Download Web Tools Platform (WTP) 1.5.4.
Discuss
Fei Fu is working on Lotus Expeditor test team in the IBM China Software Development Laboratory; he has more than six years' experience in software development and testing. He is familiar with Java, Java Enterprise Edition, and Eclipse development, and he is interested in open source software and Web 2.0. You can reach him at fufei@cn.ibm.com.
Comments (Undergoing maintenance)





