This chapter contains the following sections:
Sun Java System Portal Server 7.1 uses two types of tags: JSP tags and Desktop template tags. JSP tags are used in the JSPs and template tags are used in the HTML pages of the Desktop.
The Portal Server 7.1 software Desktop tag library consists of six parts:
Core tags that can be used on any provider or container that implement the PAPI interface.
Tags that can be used to operate on a provider or container that support the ProviderContext and ContainerProviderContext interfaces.
Tags that operate on specific container building-block providers (SingleContainer, TableContainer, TabContainer, and so on).
JSP Standard tag libraries from Apache.
Tags that support the Search function.
Tags that provide theme support in the Desktop.
This section describes the tags used in the HTML templates of the Desktop.
A template produces a channel, page, or table. The tags in a template are swapped with for real values at runtime. For example, the [tag:netmailSettings] tag swaps in a partial HTML template that has mail server information. The [tag:fontFace] tag swaps in the value of the font that the user has chosen on the Theme page. The [tag:switchColumns] tag swaps in the switchColumns.js template file, a JavaScript template, that lets users change how the columns are displayed on their Desktops.
The following is a two column table: column one lists the tag and column two provides a brief description of the corresponding tag.
url will be encoded at run time with the ProviderContext.encodeURL() method.
url will be pre-appended by the static root at run time. For example, in a Web Server instance,
[surl:/desktop/imagesnothing.gif]->/var/opt/ SUNWportal/https-servername/ portal/web-apps/desktop/imag es/nothing.gif |
dturl will be replaced by the desktop URL at run time. For example,
[dturl]?action=logout->http://server:port/portlet/dt?action=logout |
In JavaSever Pages technology, actions are elements that can create and access programming language objects and affect the output stream. JSP technology supports reusable modules called custom actions. You invoke a custom action by using a custom tag in a JSP. A tag library is a collection of custom tags. The Desktop custom tag library contains tags that you use to perform Desktop operations for JSPs.
Before tag libraries, JSPs were difficult to maintain because you were forced to use JavaBeansTM components and scriptlets as the main mechanism for performing tasks. Custom actions, that is, a tag library, alleviate this problem by bringing the benefits of another level of componentization to JSP. A tag library encapsulates recurring tasks so that they can be reused across more than one application. The tags in the JSP tag library fall into three basic groups: context setup tags, validator tags, and normal tags.
Context setup tags
These tags, which start with the prefix obtain, set up the context (storing the container or provider in question into the pageContext).
Validator tags
These tags validate that the provider in context can legally use the tags in the TLD.
Normal tags
These tags serve as wrappers of PAPI, ProviderContext, ContainerProviderContext, and the specific containers in the Sun Java System Portal Server 7.1 software.
You can pass two kinds of attributes to the Desktop library tags:
String
The simplest way to pass in an attribute is to specify it as a string, for example:
<dt:sometag attribute1="myAttribute"/> |
The string myAttribute becomes the value of attribute1. If a tag expects an integer attribute, use the following:
<dt:sometag attribute1="12345"/> |
The tag uses the corresponding Java classes (java.lang.Integer) to translate the string to an integer value. The same applies to all the primitive Java types (boolean, int, and so on).
Reference
Sometimes you cannot pass in an attribute as a string. For example, it is impossible to specify a provider object as a string. In this case, the attribute needs to be passed in as a reference defined in the pageContext. You do so by concatenating the character $ with the name of the object stored in the pageContext, for example:
<dt:sometag attribute1="$myAttribute"/> |
In this example, the value of attribute1 is whatever object is stored in the pageContext. The method pageContext.findAttribute() is used, not getAttribute(). So it is possible to define some value in the request object and pass this object in as a reference.
This mechanism is the main form of communication between tags in the Desktop tag library as well as other tags in other tag libraries (for example, jsptl).
Tags with attributes id and scope (even if they are optional) are expected to return a value as a result of using the tags. Values can be “returned” in two ways:
Print to the JspWriter stream
If the attribute id is not given when using a tag, the tag prints the value to the JspWriter stream. This results in the value showing up in the HTML code generated by the JSPs. In this case, the attribute scope is ignored.
Store the value in pageContext
If you specify the attribute id when using a tag, the tag stores the value to the pageContext as an attribute with a name specified by the id attribute. This operation overwrites whatever original value the attribute has. In addition to the id, you can also define the attribute scope. It can have one of the following values: page, request, session, or application. These values correspond to the PAGE_SCOPE, REQUEST_SCOPE, SESSION_SCOPE, and APPLICATION_SCOPE defined in javax.servlet.jsp.PageContext. This specifies the scope in which to save the value. If no or unrecognized scope is given, the default is to save it in page scope.
The tag library provides five types of exceptions.
Invalid Tag Sequence
Occurs when obtain tags are nested in an invalid sequence. See Using the Desktop Tag Library in Your Application for the sequencing of the obtain tags. The name of the first tag that violates the sequence is provided.
Invalid Provider Type
Occurs when a validation test is not passed. That is, the TLD does not support the current provider in the context. The name of the validator tag that failed is provided.
Invalid Parameter
Occurs when an attribute passed in with the tag is not a legal parameter for the tag. The name of the attribute that causes the problem is provided.
Undefined Parameter
Occurs when an attribute is passed in as reference, but the attribute is not defined in the page context. The name of the attribute is provided.
Empty Context
Occurs when there is no container or provider in the context to operate on. Most likely, the appropriate obtain tag is missing so the context is not set up properly.
The many of the Java classes that support these tags reside in a JAR file desktoptl.jar in the Web-Container-Instance/portal/web-apps/WEB-INF/lib directory. The classes for the jx.tld and jr.tld tags reside in the jsptl.jar file.
The Search tag library contains tag wrappers for the SearchContext Java API. SearchContext is an extension of the Search API with convenient methods for advanced search and search result status. The Search tag library can be divided into various categories depending upon where the tags should be used.
The search.tld file does not have any context setup or validator tags. All of the normal tags in the search.tld file have a bodycontent of empty except searchContext and search result.
A number of attributes have a value of true for rtexprvalue, which means the value for this attribute can be obtained at run time or it can be hardcoded. These attributes are listed as dynamic attributes.
When you are developing JSPs or doing Search administration tasks, you may see the following exceptions:
Invalid Tag Sequence: Must be within a searchContext Tag
Variable Undefined in Page Context
Invalid nesting of context
Error in creating search context
Search server is not defined
View Hits cannot be 0
RDM Type must be defined
Query Language must be defined
The Desktop tag library can be viewed as a wrapper of PAPI, ProviderContext, ContainerProviderContext, and specific container building-block providers in the Portal Server software. Thus, a hierarchy is implied.
For example, the ContainerProviderContext (interface) extends ProviderContext (interface). When you use a tag in desktopContainerProviderContext.tld, it also make sense to use it in desktopProviderContext.tld. Similarly, when you use a tag in desktopProviderContext.tld, it also makes sense to use provider tags in desktop.tld because ProviderAdapter implements Provider. By putting the tag in the level that provides the most use, you will not have to make duplicate tags.
At the bottom of this chain are the specific containers (single, table, and tab). Because all these containers extend JSPContainerProviderAdapter, they can use tags in their respective TLDs, as well as tags in desktopContainerProviderContext.tld, desktopProviderContext.tld, and desktop.tld.
The Desktop tag library has the following Tag Library Descriptors (TLDs) in the /var/opt/SUNWportal/portals/<portal_id>/desktop/default/tld directory. The tag library is exposed, for convenience, through using multiple TLDs, so that tags are in their appropriate functional area.
Contains core Desktop tags that bring forward the functionality available from the ProviderContext interface.
Contains tags that bring forward the functionality available from the ContainerProviderContext interface.
Contains tags to operate on providers that extend the ProviderContext.
Contains tags to operate on single container channels. Single container channels are based on JSPSingleContainerProvider or a subclass thereof.
Contains tags to operate on table container channels. Table container channels are based on JSPTableContainerProvider or a subclass thereof.
Contains tags to operate on tab container channels. Tab container channels are based on JSPTabContainerProvider or a subclass thereof.
Contains tags for theme support in the Desktop.
Contains tags for IMProvider class.
Contains tags that accept rtexprvalues for their attributes. This is a JSP Standard tag library from Apache.
Contains tags that accept attribute values specified using the “expression languages” that JSPTL introduces, which currently is only simplest possible expression language (SPEL). This is a JSP Standard tag library from Apache.
Contains tags for search support in the Desktop.
The context setup tags, which start with the prefix obtain, set up the context (storing the container or provider in question into the pageContext). Whatever tag operation that happens within these tags is done on the provider that is set in the context.
This chapter describes the context setup tags in the tag libraries. The table has four columns: the first column lists the tag name, the second describes what the tag does, the third column gives what TLD file the tag is in, and the fourth lists that tag’s attributes with brief comments.
All the context setup tags contain a value of JSP for the bodycontent tag.
Tag Name |
Description |
in TLD File |
Attributes/Descriptions |
---|---|---|---|
obtainChannel |
Gets channel object. |
desktop.tld |
channel (required) - the name of the channel |
obtainContainer |
Gets container object. |
desktop.tld |
container (required) - the name of the container |
obtainParentContainer |
Gets the parent container name. |
desktopContainerProviderContext.tld |
none |
obtainChannelFromContainer |
desktopContainerProviderContext.tld |
channel (required) - the name of the channel |
|
obtainSelectedChannel |
desktopSingle.tld |
none |
|
obtainTab |
desktopTab.tld |
tab (required) - the name of the tab |
|
obtainTabByName |
Gets the tab name. |
desktopTab.tld |
name (required) - the name of the tab |
The validator tags validate that the provider in context can legally use the tags in the TLD. Each TLD, with the exception of desktop.tld, has a validator tag defined (usually with the name of the TLD file). If the provider in context cannot use the tags defined in the TLD, an exception is thrown that is displayed on the screen and processing stops.
Users should surround tags that belong to a specific TLD with the respective validator tag. However, it is not possible to enforce that in a JSP environment. To make it easier for users to “guess” which TLD they can use or to debug the JSPs, getProviderClassName() and getContainerClassName() tags are provided in the desktop.tld. They return the class name of the container or provider in the context.
The list of Validator tags and their description are:
Validates that the provider in the context can legally use the tags in desktopproviderContext.tld.
Validates that the provider in the context can legally use the tags in desktopcontainerProviderContext.tld.
Validates that the provider in the context can legally use the tags in desktopSingle.tld.
Gets the channel name from request. This tag is in desktopSingle.tld.
Validates that the provider in the context can legally use the tags in desktopTable.tld.
Validates that the provider in the context can legally use the tags in desktopTab.tld.
This chapter lists the desktop.tld tags and their attributes. All of the normal tags in the desktop.tld file have a bodycontent of empty.
Tag Name |
Description |
Attributes |
---|---|---|
getProviderClassName |
Returns the class name of the provider that backs the channel. |
id (optional) scope (optional) |
getContent |
Returns a string buffer with the contents of the provider’s object’s default view. This method is called by the clients of the provider object to request the provider’s default view. This method may return null if the provider does not implement a default view. In this case, the provider should return false from its isPresentable() method. |
none |
getTitle |
Returns a string with the title of the channel. |
id (optional) scope (optional) silentException (optional) |
getDescription |
Returns a string with the description for the channel. |
id (optional) scope (optional) silentException (optional) |
getEdit |
Returns a string buffer with the provider’s Edit page. |
id (optional) scope (optional) |
getHelp |
Returns the help URL for this provider. The returned help URL can be either fully qualified URL string (http://server:port/portal/docs/en/desktop/usedesk.htm) or a relative path (desktop/usedesk.htm). When it is a relative path, the Desktop software resolves it to the full URL. |
id (optional) scope (optional) silentException (optional) |
getName |
Returns a string with the name of the provider, which must match the name of the provider the channel was initialized with. |
id (optional) scope (optional) |
getRefreshTime |
Returns a long with the refresh time for this provider in seconds. Use this value to determine if you should fetch a fresh default view for the provider. If the return value from this method is X, you may choose not to fetch fresh content (and use a cached copy instead) if less than X seconds has elapsed since the last time the content was refreshed. If provider content is expected to change infrequently, this method can return some value so that the provider’s content is not fetched every time the front page is drawn, thereby saving significant processing time. |
id (optional) scope (optional) |
getWidth |
Returns an integer with the suggested width for the channel to the container of the channel as to how much screen real estate it requires. The values correspond to thick, thin, full top and full bottom. |
id (optional) scope (optional) silentException (optional) |
getEditType |
Returns an integer that defines edit type either EDIT_SUBSET or EDIT_COMPLETE. |
id (optional) scope (optional) |
isEditable |
Returns a Boolean that gives the editable status of the channel. Returns true if the channel is editable; otherwise false. |
id (optional) scope (optional) |
isPresentable |
Returns a Boolean that gives the presentable status for a channel. Returns true if the channel is presentable. Searches for the key HTML with the value true on the client data for the session’s client type and returns true. If there is no such key, the method returns true if the session’s client type is named HTML. In both cases, the content-type for the session’s client type must equal text/html in order for the method to return true. |
id (optional) scope (optional) |
processEdit |
Performs the provider’s Edit page processing. Processes a form for this provider. This method is called to process form data associated with the provider. Typically, this method is called to process the Edit page generated from the getEdit() method. Usually, the client calling this method on a provider object is the desktop servlet. Form data that is passed into this method in the request has been decoded into Unicode. |
id (optional) scope (optional) |
getContainerClassName |
Returns the class name of the container that backs the container. |
id (optional) scope (optional) |
getSelectedChannels |
Returns a list of selected channel names. The list returned is a Collection of Strings. Each of the Strings is the name of a channel that has been selected. |
id (required) scope (optional) |
getAvailableChannels |
Returns a list of available channel names. The list returned is a Collection of Strings. Each of the Strings is the name of a channel that is available |
id (required) scope (optional) |
scontent |
Returns the URL of the directory that has the static content (for example, images and style sheet). This utility tag can be used anywhere. |
none |
This chapter lists the desktopProviderContext.tld tags and their attributes. All of the normal tags in the desktopProviderContext.tld file have a bodycontent of empty.
Tag Name |
Description |
Attributes |
---|---|---|
getStringProperty |
Returns a string with the property value. This is an overloaded method that can return alternately the default or localized version of the property value. |
key (required) - the name of the property localized (optional) id (optional) scope (optional) pflist (optional) |
getBooleanProperty |
Returns a Boolean that gives the value of the property. |
key (required) - the name of the property id (optional) scope (optional) pflist (optional) |
getCollectionProperty |
Returns a Java Map with the collection property. Here, a collection refers to a multi-value property. Depending on the context, it is either the analogue of Java Maps or Lists. For Lists, the returned Java Map object contains key-value pairs where the key equals the value. This is an overloaded method that can return alternately the default or localized version of the collection property. |
key (required) - the name of the property id (optional) scope (optional) pflist (optional) |
getIntegerProperty |
Returns an integer with the integer property. Throws an error if the property does not exist. |
key (required) - the name of the property id (optional) scope (optional) pflist (optional) |
getProperty |
Returns a Java Object with a property. The value returned from this method is a Java Object of type String, Integer, Boolean, or Map. Throws an error if the property does not exist. |
key (required) - the name of the property id (optional) scope (optional) |
setStringProperty |
Sets a string property. |
key (required) - the name of the property value (required) - the value of the property to be set pflist (optional) |
setBooleanProperty |
Sets a Boolean property. |
key (required) - the name of the property value (required) - the value of the property to be set pflist (optional) |
setCollectionProperty |
Sets a collection property. |
key (required) - the name of the property value (required) - the value of the property to be set pflist (optional) |
setIntegerProperty |
Sets an integer property. |
key (required) - the name of the property value (required) - the value of the property to be set pflist (optional) |
getLocalePropertiesFilters |
id (optional) scope (optional) |
|
getClientPropertiesFilters |
id (optional) scope (optional) |
|
getClientAndLocalePropertiesFilters |
id (optional) scope (optional) |
|
getClassName |
Returns a string with the class name for the provider class that this object is providing an environment for. The class name returned must implement the provider interface. This method is used to construct the provider object. It is used by container channels. |
id (optional) scope (optional) |
getTemplate |
Returns a string buffer with the desktop template. The actual template buffer returned is based on the Desktop type, locale, channel, client type, and the template name. |
file (required) - name of template to return table (optional) - hashtable - tag table used for tag swapping id (optional) scope (optional) |
getDesktopURL |
Returns a string with the Desktop URL. The Desktop URL is the absolute URL used to access the Desktop application. For example: http://server:port/portal/dt. The request object parameter is included to facilitate implementations. It may be used to build the Desktop URL by supplying the server, port, and protocol of the request. It is not required that the request object be utilized to generate the Desktop URL. |
querymap (optional) querystring (optional) pathinfo (optional) escape (optional) id (optional) scope (optional) |
getDesktopType |
Returns a string with the Desktop type. The Desktop type, also known as template type, is a string that is one of several indexes used to lookup Desktop templates and JSP files. The Desktop type is typically used to group Desktop customization files to provide different themes. |
id (optional) scope (optional) |
getLocaleString |
Returns a string representation of the locale. |
id (optional) scope (optional) |
getLocale |
Returns Java Locale object representation of the locale. |
id (optional) scope (optional) |
getLogoutURL |
Returns a string with the logout URL. The result of making a connection to the logout URL is typically the termination of the user’s session. What actually happens is dependent on the application receiving the URL connection. Providers may use this value to generate links that allow the user to end their session. |
id (optional) scope (optional) |
getStringAttribute |
Returns a string with the value of the string attribute or null if the attribute is not found. Attributes are settings that are not channel-specific. An example of an attribute might be the user’s first and last name. Channel-specific settings are called properties. Properties can be retrieved by calling the get*Property() methods. Whether a particular value is considered a property or an attribute depends on the underlying implementation of ProviderContext. |
key (required) - the name of the attribute id (optional) scope (optional) |
setStringAttribute |
Sets a string attribute. Attributes are settings that are not channel-specific. An example of an attribute might be the user’s first and last name. Channel-specific settings are called properties. Properties can be set by calling the set*Property() methods. Whether a particular value is considered a property or an attribute depends on the underlying implementation of ProviderContext. |
key (required)- the name of the attribute value (required) - the value of the attribute |
getClientTypeProperty |
key (required) clientType (optional) id (optional) scope (optional) |
|
getClientType |
Returns a string with the client type. There is no requirement as to how the client type is determined. It may be hardcoded, derived from the session, or otherwise. |
id (optional) scope (optional) |
getDefaultClientType |
Returns a string with the default client type. |
id (optional) scope (optional) |
getCharset |
Returns a string with the character set. The character set is used for decoding input and encoding output. |
id (optional) scope (optional) |
getClientPath |
Returns a string with the client path. The client path is one of several components used to lookup Desktop templates and JSPs.This allows the lookup to be client-specific. |
id (optional) scope (optional) |
getContentType |
Returns a string with the content type. This value is used to determine if a provider is able to produce content for the client’s device. |
id (optional) scope (optional) |
getSessionID |
Returns a string with the unique session identifier. The format of the return value is implementation specific. The only guarantee is that it is unique (each user session has a unique session ID). |
id (optional) scope (optional) |
getUserID |
Returns a string with the user identifier. The format of the return value is implementation specific. There is no guarantee that this value is unique (there may be multiple user sessions for a given user identifier). |
id (optional) scope (optional) |
setClientProperty |
Sets a client property. |
name (required) - the name of the property value (required) - the value of the property to be set |
getClientProperty |
Returns a string with the client property. |
name (required) id (optional) scope (optional) |
isLogMessageEnabled |
Returns a Boolean; true if the log level is set to message or higher; otherwise false. |
id (optional) scope (optional) |
isLogWarningEnabled |
Returns a Boolean; true if the log level is set to warning or higher; otherwise false. |
id (optional) scope (optional) |
logError |
Logs a message (any Java Object) if the logging level is error. The location to store logging messages is implementation dependent. |
value (required) - message to log throwable (optional) |
logMessage |
Logs a message (any Java Object) if the logging level is message or higher. The location to store logging messages is implementation dependent. |
value (required) - message to log throwable (optional) |
logWarning |
Logs a message (any Java Object) if the logging level is warning or higher. The location to store logging messages is implementation dependent. |
value (required) - message to log throwable (optional) |
getDefaultChannelName |
Returns a string with the default channel name. |
id (optional) scope (optional) |
getTopChannelName |
Returns the top channel name for the current request. |
id (optional) scope (optional) |
getStaticContentPath |
Gets the URI prefix to web server static content. |
id (optional) scope (optional) |
getProviderVersion |
Get the version of the provider schema for the current channel. |
id (optional) scope (optional) |
encodeURLParameter |
URL encodes a unicode string. |
id (optional) scope (optional) key (required) |
decodeURLParameter |
Decodes the URL encoded Unicode string. This tag just returns back the original string passed in. |
id (optional) scope (optional) key (required) |
encodeURL |
Encodes a URL. Rewrites the URL to include the session id. |
url (required) id (optional) scope (optional) |
escape |
Escapes a String using an encoder class that encodes a specific type of markup. This tag is used to allow provider code to encode content in a device-unaware manner. |
id (optional) scope (optional) unescaped (required) |
This chapter lists the desktopContainerProviderContext.tld tags and their attributes. All of the normal tags in the desktopProviderContext.tld file have a bodycontent of empty.
Tag Name |
Description |
Attributes |
---|---|---|
getContent |
Returns a string buffer with the content of the named channel. This method is provided for convenience. It gets the provider object for the named channel and calls Provider.getContent(). |
channel (required) - the name of the channel id (optional) scope (optional) |
This chapter lists the desktopTab.tld tags and their attributes. All of the normal tags in the desktopTab.tld file have a bodycontent of empty.
Tag Name |
Description |
Attributes |
---|---|---|
getAvailableTabs |
Returns a list of available tabs. The list returned is a Collection of Strings. Each of the Strings is the name of an Unmodifiable Tab that is available. |
id (optional) scope (optional) |
getSelectedTabs |
Returns the list of selected tabs. The list returned is a Collection of Strings. Each of the Strings is the name of an Unmodifiable Tab that is selected. |
id (optional) scope (optional) |
getSelectedTab |
Returns the selected tab, the current selected Unmodifiable Tab in the user’s session. |
id (optional) scope (optional) |
getMakeTab |
Returns the make tab, the tab spec to be used for "Make My Own tab" creation by the user. |
id (optional) scope (optional) |
getStartTabNam |
Returns a string with the start tab Name, the name of the tab to be displayed when the user logs in. |
id (optional) scope (optional) |
getSelectedTabName |
Returns a string with the selected tab Name, the current selected tab in the user’s session. |
id (optional) scope (optional) |
getTabURL |
Returns the Tab URL. This method gets the tab URL used to switch the selected tab on the user’s desktop. |
id (optional) scope (optional) |
getName |
Returns a string with the name of the tab. |
id (optional) scope (optional) |
getDesc |
Returns a string with the description of the tab. |
id (optional) scope (optional) |
getDisplayName |
Returns a string with the display name of the tab. |
id (optional) scope (optional) |
getEncodedName |
Returns a string with the HTML encoded name of the tab. |
id (optional) scope (optional) |
isPredefined |
Determines whether the tab is predefined or not and returns a boolean that gives the predefined status of a tab. |
id (optional) scope (optional) |
isRemovable |
Returns a Boolean that gives the removable status of the tab. Returns true if the tab is removable; otherwise false. |
id (optional) scope (optional) |
isRenamable |
Returns a Boolean that gives the renamable status of the tab. Returns true if the tab is renamable; otherwise false. |
id (optional) scope (optional) |
This chapter lists the desktopTable.tld tags and their attributes. All of the normal tags in the desktopTable.tld file have a bodycontent of empty.
Tag Name |
Description |
Attributes |
---|---|---|
getColumns |
Returns a list of channel names that belong in that particular column. |
column (required) id (required) |
getColumnWidth |
Returns the width of a column (a percentage with respect to the entire Desktop). Valid columns are left, center, and right. |
column (required) id (required) |
getHasFrame |
Returns a Boolean that gives the frame status of the channel. Returns true if the channel has a frame; otherwise false. |
id (optional) scope (optional) |
getIsMinimized |
Returns a Boolean that gives the minimized status of the channel. Returns true if the channel is minimized; otherwise false. |
id (optional) scope (optional) |
getIsMovable |
Determines whether the channel is movable or not and returns a Boolean that gives the movable status of a channel. |
id (optional) scope (optional) |
getProviderCommand |
Gets the HTML code needed to display the provider commands (minimize channel, help screen, edit channel, and so forth). The commands are put in a Map. The keys for the Map are minMaximizedCommand, helpCommand, editCommand, detachAttachCommand, and removeCommand. |
id (optional) scope (optional) |
getIsDetached |
Returns a Boolean that gives the detached status of the channel. Returns true if the channel is detached; otherwise false. |
id (optional) scope (optional) |
getDetached |
Returns the detached channels list. The list returned is a Collection of Strings. Each of the Strings is the name of a channel. The channels returned are not necessary channels that have been detached from the desktop. The tag getIsDetached should be used to verify that a channel has been detached. |
id (optional) scope (optional) |
getWindowName |
Returns a string with the window name for the detached window when a channel is detached. |
id (optional) scope (optional) |
isPopup |
Determines whether the page is being drawn for a popup channel. Returns true if the table container action is a popup and returns false otherwise. |
id (optional) scope (optional) |
getPopupWindowWidth |
Returns an integer with the popup window width for the detached window when a channel is detached. |
id (optional) scope (optional) |
getPopupWindowHeight |
Returns an integer with the popup window height for the detached window when a channel is detached. |
id (optional) scope (optional) |
getContents |
Returns a string buffer with the contents of all non-minimized and selected channels of the table container. The contents are put in a Map with the channel name as the key. |
id (required) scope (optional) |
getChannelsInCategory |
Returns the map values of channel names included in the category. |
category (required) id (required) scope (optional) |
This chapter lists the desktopTheme.tld tags and their attributes. All of the normal tags in the desktopTheme.tld file have a bodycontent of empty.
Tag Name |
Description |
Attributes |
---|---|---|
getGlobalThemes |
Returns the list of globally defined themes. The list returned is a Collection of Strings. Each of the Strings is the name of a globally defined theme. |
id (required) scope (optional) |
getSelectedName |
Returns the name of the selected theme. The name returned can be the name of one of the globally defined themes or CustomTheme. If CustomTheme is returned, this means the user has defined and is using the custom defined theme. |
id (required) scope (optional) |
setSelectedName |
Sets a theme for the current user. The theme to be set can be one of the globally defined themes or a CustomTheme. |
value (required) - the name of the theme set |
getAttribute |
Returns the value of a theme attribute. Get a specific attribute value of a specific theme. |
name (required) - the name of the attribute. Possible values are: bgColor, borderColor, titleBarColor, fontColor, borderWidth and fontFace theme (optional) - the name of the theme. If this is not specified, the currently selected theme is used. requestOverride (optional) true or false - Whether to use value in the request to override the theme value. If this is not specified, false is assumed. This is useful in the preview case. id (optional) scope (optional) default - the default value. If getAttribute() of a theme returns null, and a default value is defined in the tag, then return the default value. |
setCustomAttribute |
Sets a customized value in the CustomTheme |
name (required) - the name of the attribute. Possible values are: bgColor, borderColor, titleBarColor, fontColor, borderWidth and fontFace value (required) - the value to be set |
This chapter lists the normal tags and attributes for the searchContext Java API in the Search tag library.
Tag Name |
Description |
Attributes |
---|---|---|
searchContext |
Main outer tag that encloses all other tags. |
bodycontent - JSP rdmServer (optional) - search server - http://.../search1/search or https://../search1/search rdmType (optional) - rd-request (default), taxonomy-request, schema-request, server-request or status-request ql (optional) - query language query (optional) - dynamic attribute |
This chapter lists the pre-search tags and attributes in the search.tld file. These tags are used before executing a search. Before a successful search can be executed these tags must set a value for:
setRDMServer
setRDMType
setQuery or setCriteria
Tag Name |
Description |
Attributes |
---|---|---|
setRDMServer |
Sets the RDMServer variable. The server URL should be set explicitly. Format: http:// or https://hostname:port/search1/search Value has to be set. |
rdmServer (required) - server URL; can be an expression or a hardcoded string value. |
setRDMType |
Sets the RDM Request type. RDMType - Can be one of: rd-request: The default request type. Resource descriptions (documents). taxonomy-request: Taxonomy. schema-request: The schema. server-request: Server information. status-request: Server status information. Set value explicitly; the default set by the system may not return the expected results. |
rdmType (required) - string |
setViewAttributes |
Sets the search result attributes that are returned for the search. This is an optional tag. It assumes the default values if not set explicitly. |
viewAttributes (required) - string: null (all) or comma delimited list of attributes. |
setSessionID |
The Search Server needs to validate the user’s identity for document level security. This tag is a wrapper for setSessionID(String) method in SearchContext. The JSP gets the portal access Token string and passes it along to the search server using this tag. |
sessionID (required) - string |
setViewOrder |
Sets the sorting order for results. |
viewOrder (required) - string: null or comma delimited list of attributes each proceeded with + for ascending order or - for descending order. For example: —score — sort results based on the descending relevancy (default) +title, —score — sort results by title first, score second. |
setCategory |
Sets the category id. It is mainly required for browsing and category searches. The category is appended to the query string based on the RDMType and query language in the executeSearch tag. |
category (required) - string: current category level; if not set, the search is not restricted by category. For example, category=Internal:Engineering:Java |
setSearchAll |
Specifies whether to serach in the current category only, or in all the sub-categories. Default value is true. |
searchAll (required) - Boolean |
setFirstHit |
setFirstHit takes a string input. Sets the starting hit for search results. In other words, start from 1, start from 11 and so forth. It corresponds to the setFirstHit() method in the Search API. Results are returned from this hit. This is an optional tag. Alternately you can use setPage and setViewHits. |
fromHit (required) - integer |
setViewHits |
Sets the maximum number of hits returned. |
viewHits (required) - integer - dynamic attribute |
setQuery |
Query string. Either this value has to be set or else setCriteria has to be set. |
query (required) - string - dynamic attribute |
setDatabase |
Sets the name of the database to search. |
database (required) - string - dynamic attribute |
setPage |
Sets the first hit by taking the view hits (using setViewHits) as a page size. Do not use, setPage and setFirstHit together.. |
page (required) - integer - dynamic attribute |
setQueryLanguage |
Sets the query language. ql - Can be one of: search: The default Search query language. Searches documents or the taxonomy. taxonomy-basic: Used for requesting branches or parts of the taxonomy. schema-basic: Queries the Search schema. url: Retrieves RDs by URL (scope=url). |
ql (required) - string |
setCriteria |
Sets the query string in a list format. Useful in advanced search. The list should have an operand, operator and a value.The list of valid operator’s are defined in the SearchContext API. The operand can be a schema field. The user can bypass this tag and just use the setQuery tag directly by converting a complex query into the syntax that the search engine requires. The setCriteria tag is a wrapper for the setScope(list) method in the searchContext API. This method basically parses the list and converts it into a string. For example, author CONTAINS xyz. Either this value has to be set or else setQuery has to be set. |
criteria (required) - string - dynamic attribute |
The search.tld includes the tag that executes the search.
Tag Name |
Description |
Attributes |
---|---|---|
executeSearch |
Tag for the execute method in SearchContext API. Executes search after doing some validation of the search parameters and query string. |
none |
This chapter lists the tags and attributes in search.tld file. These tags are related to search results and are used after a search is executed. They provide various counts and help display the search results.
Tag Name |
Description |
Attributes |
---|---|---|
getNextResult |
Search results iterator, creates a context for each result in the search result stream. |
bodycontent - JSP input (required) -search result document input (required) — search result stream |
getResult |
Retrieves the result stream from the previous search. |
id (optional) scope (optional) |
getValue |
Returns a string value of the attribute or returns a string value of a multivalue attribute with index. This tag must be used within the getNextResult tag. |
Attribute (required) - string - attribute name escape (true for HTML encoding) id (optional) scope (optional) truncate (optional) - specifies the number of characters to return in the attribute |
getURL |
Returns a string with the search result URL as a string. This tag must be used within the getNextResult tag. |
escape (optional) id (optional) |
getHasNextPage |
Returns true if there are more hits for the next page by considering the values of viewHits and the current page. |
id (optional) scope (optional) |
getHasPreviousPage |
Returns true if there is a previous page. Value based on viewHits and current page value. |
id (optional) scope (optional) |
getNoHits |
Returns true if no matching hits were found. This is a convenience tag. |
id (optional) scope (optional) |
getHitCount |
Returns the total number of results that matched the query. |
id (optional) scope (optional) |
getToHit |
Returns the last hit being displayed on a page. The value is based on firstHit and viewHits. |
id (optional) scope (optional) |
getPage |
Returns the current page. If the value is not set, calculates the page based on viewHits and firstHit. |
id (optional) scope (optional) |
getTotalDocuments |
Returns the total number of documents in the database. |
id (optional) scope (optional) |
getTotalPages |
Returns the total number of pages of hits that are available. The value is calculated from viewHits and hitCount. |
id (optional) scope (optional) |
getResultCount |
Returns the number of results returned by the search. Returns -1 for an error. |
id (optional) scope (optional) |
This chapter lists the other available tags and their corresponding attributes in search.tld file. All these tags in the search.tld file have a bodycontent of empty.
Tag Name |
Description |
Attributes |
---|---|---|
getSearchString |
Returns a string with a the search query being executed. Good for debugging. |
id (optional) scope (optional) |
getCategory |
Returns a string with the current category name or else set to root. |
id (optional) scope (optional) |
getFirstHit |
Returns the starting hit being displayed. |
id (optional) scope (optional) |
getSessionID |
Returns a string with a user’s session id. It has no value unless previously set. |
id (optional) scope (optional) |
getQuery |
Returns the query string; returns an empty string if not set. |
id (optional) scope (optional) |
getViewHits |
Returns viewHits, an integer that defines the maximum number of hits returned (range 0-100). The default value is 8 if not set or set outside of range. |
id (optional) scope (optional) |
getDatabase |
Returns the database being searched. |
id (optional) scope (optional) |
getMaximumPages |
Returns the maximum number of pages from any search executed in the current search context. Useful for building the previous or next page iterator. |
id (optional) scope (optional) |
This chapter contains a listing of all the common tags in the Desktop template files.
Font chosen
Default font for the Desktop (sans-serif)
Default font for the Desktop (sans-serif)
Default font for the Desktop (sans-serif)
Color of font chosen
Provider background color chosen
Color of the channel border. The border color can be changed by user in the desktop custom theme page.
Color of title bar
Directory you defined for the deployment URI during installation.
Directory designation for chosen locale
Product name
Provider/Channel title
The title of the provider/channel
Name of selected tab
Name of the front container
The top level container name for the TemplateTabContainer
The channel name
Channel name as defined in the channel display profile definition.
The theme edit channel name at run time, this will be either the presetThemeContainer or the customThemeContainer.
error content
Content of the provider
Channel content in the detached window
Content of the channel
Channel content in the detached window
Provider/channel content (HTML) inserted here
display value
Produces a stack trace
Inserts content in the maximize mode
A text that is used as an alternate for the minimize icon
A text that is used as an alternate for the maximize icon
Alternated string for the minimize or normalize image in the title bar, this is a localized string, the state of minimize or maximize is determined at run time.
Text for the alt tag for the remove icon
Text for the alt tag for the detach/attach image in the title bar, this is a localized string. The detach or attach mode is determined at run time.
Inserts minimize /maximize icon
Alternated string for the remove image in the title bar, this is a localized string
Text for the alt tag for the edit icon
Text for alt message
Inserts bulletColor.js into this template
Inserts toolbarRollover.js into this template.
Inserts banner.template into this template
Inserts menubar.template into template
Inserts contentBarInContent.template into this template
Inserts contentBarInLayout.template into this template
Inserts arrangeProvider.js template into this template
Inserts performSubstitution.js template
Inserts performColumnSubstitution.js template
Inserts selectAll.js template
Inserts switchColumns.js template
Inserts layoutFullTop.template into this template
Inserts layoutFullBottom.template into this template
Inserts openURLInParent.js template
Inserts popupMenubar.template template
Inserts launchPopup.js template
Replaced with inlineError.template if error has occurred
Inserts the removeCommand.template
If the channel is detached, insert the detachCommand.template; if the channel is attached, then insert the attachCommand.template.
Inserts the editCommand.template
Inserts helpHref.template
Inserts the minMaximizeCommand.template
Used to dynamically build edit pages. Should not be edited.
Header.
Attribute Name.
Selected attribute.
Attribute value.
String.
Selected.
Options.
Process.
isAppMandler.
Mail display error.
Used to display link for the application helper editing / URL to edit
URL location
the logout URL
URL of Desktop to return to
URL of the channel to be removed
?action=process&provider= thecontainername&thecontainername. channelAction=remove& thecontainername.targetProvider =providername |
URL of new location
URL of Edit page for this channel
?action=edit&provider= theeditcontainername&targetprovider= providername& containerName=thecontainername |
URL of the channel to be detached
action=process&provider= thecontainername&thecontainername.channelAction= attach&thecontainername.targetProvider= providename |
A URL to show the channel in maximize mode
A URL to show the channel in either the minimize or the normal mode, the mode is decided at run time
URL of channel to minimize or maximize
?action=process&provider= thecontainername &thecontainername.channelAction= maxmize&thecontainername.targetProvide r=providername ?action=process&provider= thecontainername&thecontainername. channelAction= minimize&thecontainername. targetProvid er=providername |
Run time path for the detach image
Run time path for the edit image
Run time path for the remove image
Run time path for the help image
Run time path for the minimized or the maximized image, the state of minimize or maximize is determined at run time.
Run time path for the normalized image
Style sheet used by the Desktop for the banner and tabs templates
Help link for Desktop
Help link for frames on the Desktop
Used to space gifs or channels
Icon that shows up arrow
Icon that shows down arrow
Icon that shows arrow pointing left
Icon that shows arrow pointing right
A URL that points to the normal image
A URL that points to the maximize image
A URL that points to the maximize image
A URL that points to the attach image
Icon for thin-wide layout
Icon for wide-thin layout
Icon for thin-wide-thin layout
Icon for thin-thin-thin layout
Blue button to denote Home, Help, Logout, and so on
Red button to denote home, help, logout, or whatever has been chosen.
Used to space gifs or channels
Logo gif of the product name
Blue button to denote Home, Help, Logout, and so on
Help link for Desktop
Icon for help in channel title bar
Inserts the channel command button links (maximize, detach, and so on)
Provider Timeout in seconds
The theme edit channel name at run time, this will be either the presetThemeContainer or the customThemeContainer.
Channel content in the detached window
This chapter contains the following sections:
The tags described below are used by AddressBookProvider and providers who extend this provider (such as LotusNotesAddressBookProvider and MSExchangeAddressBookProvider).
Used to display the application launch link
Used as a placeholder to put in all of the address book entries
Displays first name
Displays last name
Displays common name
Displays email
Displays email as a link
Displays error message
Displays a summary of the entries
Displays summary
Displays entries
Ab display client URL
The tags described below are used by AppProvider.
JavaScript variable default for launching Bookmark windows (taken from preferences)
List of bookmark links
Number of bookmarks
Name of the bookmark
URL of the bookmark
Checkable list of bookmarks for Edit page in table format
Default for checkboxes of how the bookmark should be opened (new window, existing window, and so on)
Used to reference the URLs in the edit page
Name of Bookmark used on edit page
URL for bookmark used on edit page
The value for this is either CHECKED or “” based on the window preference specified in edit page
Localized string from resource bundle displaying the text for window options on the edit page.
The value for this is either CHECKED or “” based on the window preference selected in edit page
Localized string from resource bundle displaying the text for window options on the edit page.
The value for this is either CHECKED or “” based on the window preference selected in edit page
Localized string from resource bundle displaying the text for window options on the edit page.
URL for bookmark used for constructing the channel content.
Name of bookmark used in the channel content.
The tags described below are used by CalendarProvider and providers who extend this provider (such as LotusNotesCalendarProvider and MSExchangeCalendarProvider).
Used to display the application launch link
start hour for 0 based 24-hour clock
start hour for 1 based 24-hour clock
start hour for 0 based 12-hour clock
start hour for 0 based 12-hour clock
end hour for 0 based 24-hour clock
end hour for 1 based 24-hour clock
end hour for 0 based 12-hour clock
start hour based on user preference of 12 or 24 hour clock format
end hour based on user preference of 12 or 24 hour clock format
hour based on user preference of 12 or 24 hour clock format
minutes of the start time
am or pm identifier
Calendar display day view event
Calendar display day view task
Calendar display day view task
end hour based on user preference of 12 or 24 hour clock format
minutes of the due time
minutes of the end time
description separator specified by the resource bundle ”seperatorDescription’ value
event description
event location
event summary
if the event is an All Day event, then it is identified by the resource bundle ”CalendarProvider-allDayEvent’ value
task summary
task description
Calendar display day view overdue task
hour of task for 12-hour clock
month the task was due
day of the month the task was due
year the task was due
overdue task summary
minutes of the task
task location
start time of completed task
today’s day of week
today’s month
today’s day in month
today’s year
task list content
event list content
other tasks list content
number of overdue tasks for today
overdue task list content
If tasks exist, then the task header is identified by the resource bundle ”dueTasks’ value
if overdue tasks exist, then the overdue task header is identified by the resource bundle ”overdueTasks’ value
If events exist, then the event header is identified by the resource bundle ”dueEvents’ value
If other tasks exist, then the other tasks header is identified by the resource bundle ”otherTasks’ value
If the event is in conflict, then it is identified by the resource bundle ”conflict’ value.
error message
day of week 0
day of week 1
day of week 2
day of week 3
day of week 4
day of week 5
day of week 6
end hour for 0 based 12-hour clock
start hour based on user preference of 12 or 24 hour clock format
minutes of the start time
am or pm identifier
end hour based on user preference of 12 or 24 hour clock format
minutes of the end time
am or pm identifier
event summary
If the event is an All Day event, then it is identified by the resource bundle ”CalendarProvider-allDayEvent’ value
hour based on user preference of 12 or 24 hour clock format
am or pm identifier
minutes of the task
task summary
day in month 0
day in month 1
day in month 2
day in month 3
day in month 4
day in month 5
day in month 6
events for day in month 0
tasks for day in month 0
events for day in month 1
tasks for day in month 1
events for day in month 2
tasks for day in month 2
events for day in month 3
tasks for day in month 3
events for day in month 4
tasks for day in month 4
events for day in month 5
tasks for day in month 5
events for day in month 6
tasks for day in month 6
today’s day of week
today’s month
today’s day in month
today’s year
day of week content
week content for week 0
week content for week 1
week content for week 2
week content for week 3
week content for week 4
event summary information
task summary information
event summary
task summary
today’s day of week
today’s month
today’s day in month
today’s year
start hour for 0 based 12-hour clock
end hour for 0 based 12-hour clock
if the event is in conflict, then it is identified by the resource bundle ”conflict’ value.
start hour based on user preference of 12 or 24 hour clock format
minutes of the start time
am or pm identifier
end hour based on user preference of 12 or 24 hour clock format
minutes of the end time
am or pm identifier
event summary
If the event is an All Day event, then it is identified by the resource bundle ”CalendarProvider-allDayEvent’ value
event summary
hour based on user preference of 12 or 24 hour clock format
minutes of the end time
am or pm identifier
task summary
today’s date information
day of week 0
day of week 1
day of week 2
day of week 3
day of week 4
day of week 5
day of week 6
day in week 0
day in week 1
day in week 2
day in week 3
day in week 4
day in week 5
day in week 6
events for day in week 0
tasks for day in week 0
events for day in week 1
tasks for day in week 1
events for day in week 2
tasks for day in week 2
events for day in week 3
tasks for day in week 3
events for day in week 4
tasks for day in week 4
events for day in week 5
tasks for day in week 5
events for day in week 6
tasks for day in week 6
summary content
day content
week content
month content
client application URL
The tags described below are used by LoginProvider.
Inserts the persistent cookie template
Inserts the libertyLogin.Template
Help link for login
Inserts the liberty preLogin URL. The value is specified in the channel property preLoginURL which is typically of the form:
http://www.siroe.com:80/amserver/preLogin?metaAli as= www.siroe.com&goto=http://www.siroe.com:80/por tal/dt |
The IMProvider content page uses a custom tag library defined in a file called im.tld which is installed into the /var/opt/SUNWportal/portals/<portal_id>/desktop/default/tld directory. The im.tld file defines the following tags:
Tag Name |
Description |
Attributes |
---|---|---|
getContactGroups |
Returns list of contact groups that the user has defined. The list is returned as a Collection of Strings where each String is the display name for a contact group. |
id (optional) scope (optional) |
getContactGroup |
Returns the list of contacts in the named contact group. The list is returned as a Collection of internal objects that can be passed to the obtainContact tag. |
group (required) - The name of the contact group. id (optional) scope (optional) |
getUsername |
Returns the instant messaging username for the user. |
id (optional) scope (optional) |
getToken |
Returns the login token for the user (either an Sun Java System Access Manager software SSOToken or the user’s password.) |
id (optional) scope (optional) |
obtainContact |
A context setup tag that is used to obtain the presence information for the indicated contact. The remaining tags can be used inside this tag. |
contact (required) - The internal identifier of the contact, typically obtained from the getContactGroup tag. |
getContactPresence |
Returns the current presence status for the contact. The status can be: AWAY, BUSY, CLOSED, FORWARDED, IDLE, OPEN, OTHER. These are from the PresenceSession class in the instant messaging API. |
id (optional) scope (optional) |
getContactName |
Return the common name for the contact. |
id (optional) scope (optional) |
getContactUsername |
Returns the instant messaging user name for the contact. |
id (optional) scope (optional) |
getDateTime |
Returns the update time. |
format (required) id (optional) scope (optional) |
isSecureMode |
Returns boolean indicating whether the channel is being accessed through the Secure Remote Access Gateway component and the Netlet is loaded. |
id (optional) scope (optional) |
getCodebase |
Returns the codebase to use to download the applet. This takes into account whether the channel is being accessed via the Secure Remote Access Gateway component and the Netlet is loaded. |
id (optional) scope (optional) |
getIMServer |
Returns the -server argument to pass to the IM client. This takes into account whether the channel is being accessed via the Secure Remote Access Gateway component and the Netlet is loaded. |
id (optional) scope (optional) |
The entire interface to the Instant Messaging server APIs is in the getContactGroup tag. This tag will fetch all of the presence information and cache it in the request. The remaining tags will simply fetch the information out of the cache.