com.ibm.portal.admin
Interface Client

All Superinterfaces:
Identifiable, TimeStamped
All Known Subinterfaces:
ModifiableClient

public interface Client
extends TimeStamped, Identifiable

Admin model interface for client objects. This class provides developers of administrative portlets an interface to access the client definitions that are installed at the portal. A client definition that has been installed at the portal has the following data:

Object ID (required)
identifies this client object.
User Agent Pattern (required)
a string expression that describes a pattern for a user agent string. At runtime, when the WebSphere portal receives a HTTP request, this user agent pattern is checked against the definition in the user agent header of the HTTP request. If the user agent pattern matches, the portal takes the remaining information of this client object
Manufacturer (optional)
The manufacturer (that is the organisation or company that developed the client) of the client. This
Model (optional)
The model specification of the client.
Version (optional)
A version identifier for the browser. This definition has no effect at runtime, but may help administrators to manage the portal client list.
Markup Name (required)
Denotes the markup that the client expects (for example "html", "wml", xhtml"). Although there is no consistency check in the model, administrative portlets should ensure that only markups that are available from the "Markups" list can be specified
Markup Version (optional)
Denotes the version of the markup. There can be cases where portal JSPs evaluate the markup version to enable or disable certain capabilities of the JSPs.
Capabilities (optional)
a List of String objects that identify certain capabilities of the client browser (example: the capability "JavaScript" denotes the capability of supporting JavaScript embeddings in the HTML code).
Creation Date (required)
denotes the point of time when this client object has been created.
Modification Date (required)
denotes the point of time when this client object has been modified last.

The object that implements this interface represents one client definition that has been registered at the portal. A client object is accessed by the methods get(ObjectID) and iterator() of a ClientList object

Since:
6.1.0
See Also:
ClientList

Method Summary
 java.util.Iterator<java.lang.String> getCapabilities()
          Return a collection of Strings that denote the client capabilities.
 java.lang.String getManufacturer()
          Return the manufacturer String, or null if no manufacturer information has been specified.
 Markup getMarkup()
          Returns the markup instances of the client.
 java.lang.String getMarkupVersion()
          Return the markup version that the client requires.
 java.lang.String getModel()
          Return the model specification of the client or null if there is no model information for this client.
 java.lang.String getUserAgentPattern()
          Return the client's user agent pattern.
 java.lang.String getVersion()
          Return the client version string or null if there is no client version information for this client.
 
Methods inherited from interface com.ibm.portal.TimeStamped
getCreated, getLastModified
 
Methods inherited from interface com.ibm.portal.Identifiable
getObjectID
 

Method Detail

getUserAgentPattern

java.lang.String getUserAgentPattern()
                                     throws ModelException
Return the client's user agent pattern. At runtime, this pattern is compared with the user agent string in the HTTP header of incoming requests. If the User Agent string of the HTTP request matches with this ClientElement object, the portal renders its output in the markup that is specified by this object.

This class utilizes the pattern evaluation of the Jakarta Regexp package. Refer to the online Javadoc documentation of the RE class for details about the pattern syntax.

Returns:
String the user agent pattern.
Throws:
ModelException - - An error occurs wile accessing the database

getManufacturer

java.lang.String getManufacturer()
                                 throws ModelException
Return the manufacturer String, or null if no manufacturer information has been specified.

Returns:
String The manufacturer String
Throws:
ModelException - - An error occurs wile accessing the database

getModel

java.lang.String getModel()
                          throws ModelException
Return the model specification of the client or null if there is no model information for this client.

Returns:
String The model string
Throws:
ModelException - - An error occurs wile accessing the database

getVersion

java.lang.String getVersion()
                            throws ModelException
Return the client version string or null if there is no client version information for this client.

Returns:
String The client version
Throws:
ModelException - - An error occurs wile accessing the database

getMarkupVersion

java.lang.String getMarkupVersion()
                                  throws ModelException
Return the markup version that the client requires.

Returns:
String The markup version
Throws:
ModelException - - An error occurs wile accessing the database

getCapabilities

java.util.Iterator<java.lang.String> getCapabilities()
                                                     throws ModelException
Return a collection of Strings that denote the client capabilities. The capabilities definitions specifies features that the client can support (Examples: JavaScript, XSL, etc). These can be used inside the JSP resources. The purpose of the Client capabilities is to trigger client specific code sequences inside JSPs.

Returns:
Iterator a collection of String objects that specify the Client capabilities
Throws:
ModelException - - An error occurs wile accessing the database

getMarkup

Markup getMarkup()
                 throws ModelException
Returns the markup instances of the client.

Returns:
the markup instances of the client, never null
Throws:
ModelException - in case of error