5.6 Lotus Collaborative Components API

 < Day Day Up > 



5.6 Lotus Collaborative Components API

Lotus Collaborative Components are building blocks (APIs and JSP tag libraries) for integrating the functionality of Lotus Domino, Lotus Sametime, Lotus QuickPlace, and Lotus Discovery Server into the portal. The IBM redpaper WebSphere Portal 4.12 Collaboration Services, REDP 0319 discusses this topic in more depth.

The Collaborative Components can be divided into Java Classes and Methods (cs.jar) and JSP, JavaScript tag libraries (people.tld and menu.tld). JSP tag libraries were discussed in Chapter 4, "Using custom Domino JSP tag libraries". This section covers only the core API of the Collaborative Components.

Collaborative Components are implemented in Java and include no platform-specific code, so they can be used on any J2EE-compliant server.

Overview of key objects

The CS.jar, Collaboration Service package contains all the Java implementations of the collaborative components. There are classes and methods for leveraging Domino, QuickPlace, Sametime, and Discovery Server.

For more detailed information about these classes, see the documentation provided as a Javadoc within the Collaborative Components enterprise application: the cs.ear file.

Some key objects are the following:

  • CSEnvironment: Initializes the server environment and retrieves credentials for the logged-in user.

  • CSCredentials: Represents the authentication information for the logged-in user. CSFactory uses these credentials to authenticate against the worker servers (Sametime, QuickPlace, and so forth).

  • CSFactory: Constructs the Java service objects and generates a connection to the appropriate worker server.

    The CSFactory object instantiates these service objects. The developer is responsible for calling the cleanup() member function on each object before they go out of scope. This cleanup function releases any resources a service object holds.

  • DominoService: Provides standardized access to all versions of Domino from R4.67.

    • ViewInfo: Represents information about a view in a Domino database.

    • ColumnInfo: Contains information about the columns in a Notes view.

    • RowInfo: Represents data from one row in a Notes view.

    • CalendarDayInfo: Encapsulates all the calendar entries for a particular day.

    • EntryInfo: Contains information about a single calendar entry.

  • QPService: Provides the ability to create a QuickPlace.

  • PeopleService: Provides Sametime awareness (users logged onto Sametime) plus the ability to obtain information about a specified person, such as their e-mail address.

  • DiscoveryServerService: Provides the ability to discover, search for, and retrieve Categories, People, Places, and Documents from a Discovery Server.

How to get started

  1. Set up a development environment.

    At a minimum you must install the Collaborative Components jar files on your development machine and make them available to WebSphere Studio Application Developer. The required jar files are:

    • cs.jar

    • commres.jar

    • kdsapi.jar

    • kdsw.jar

    • ncsow.jar

    • stcommsrvrtk.jar

    The simplest way to accomplish this task is to load the cs.ear file into WebSphere Studio Application Developer. This provides the additional benefit of installing the tag libraries and the sample programs that come with the Collaborative Components package. To install cs.ear on your machine, choose the Import option from the WebSphere Studio Application Developer file menu and select EAR File as the import source. On the EAR Import screen enter a new project name and enterprise application project name. When you are finished, your screen should look similar to the one in Figure 5-15 on page 272.

    click to expand
    Figure 5-15: Structure of portlet after cs.ear file has been imported

  2. Configure the properties file according to your Domino servers.

    In the project you just created, expand the folder <project name>/WebContent/config. Edit the CSEnvironment.properties file and enter the host names for the Discovery Server, Domino Directory, and QuickPlace servers.

    Example 5-9: CSEnvironment.properties file example in config folder

    start example
     ############################################################## # SAMETIME properties # Only valid property is enabled. Other values configured # through hostAddress.xml ############################################################## CS_SERVER_SAMETIME.enabled=true ############################################################## # QUICKPLACE properties # enabled indicates whether or not QP creation is allowed. ############################################################## CS_SERVER_QUICKPLACE.enabled=true CS_SERVER_QUICKPLACE_1.hostname=my.server.com CS_SERVER_QUICKPLACE_1.version=3.0 ############################################################## # DISCOVERY SERVER properties ############################################################## CS_SERVER_DISCOVERY_SERVER.enabled=true CS_SERVER_DISCOVERY_SERVER_1.hostname=my.server.com CS_SERVER_DISCOVERY_SERVER_1.version=2.0 ############################################################## # DOMINO DIRECTORY properties # (LDAP server) # Only valid property is hostname. Leave enabled flag as true. ############################################################## CS_SERVER_DOMINO_DIRECTORY.enabled=true CS_SERVER_DOMINO_DIRECTORY_1.hostname=my.server.com ############################################################## # # LDAP server performance properties # (LDAP server) # Leave enabled flag as true, if using WMM. # Setting this flag to false will improve performance # while using Domino as the primary (and only) LDAP server # in the Portal. ############################################################## CS_PERF_PROP_USEWMM.enabled=true 
    end example



 < Day Day Up > 



Portalizing Domino Applications for Websphere Portal
Portalizing Domino Applications for Websphere Portal
ISBN: 0738499811
EAN: 2147483647
Year: 2003
Pages: 103
Authors: IBM Redbooks

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net