Sun ONE logo     Previous     Contents     Index     Next     
Sun ONE Portal Server 6.0 Desktop Customization Guide



Chapter 5   Understanding the Sample Portal


This chapter describes the sample portal that you can choose to install on your system during the Sun™ ONE Portal Server installation. See the Sun ONE Portal Server 6.0 Installation Guide for more information on installing the sample portal.

This chapter contains the following sections:

Overview of the Sample Portal

The sample portal consists of sample containers, each of which produces a different looking Desktop. A container is a channel that is able to hold and organize content from other channels.The sample portal is created from the following containers:

  • JSPTabContainer - Creates a Desktop that contains multiple containers selected using different tabs. Normally, each tab is constructed by using JSPTabCustomTableContainer, but you can use any container. This container is JSP-based. Its provider is JSPTabContainerProvider.

  • JSPTableContainer - Creates a Desktop that arranges a maximum of five sub-containers into the channel arrangement. This container is JSP-based. Its provider is JSPTableContainerProvider.

  • FrameTabContainer - Creates a Desktop using frames. The left-hand frame enables you to navigate, and the right-hand frame displays the channels. This container is JSP-based. Its provider is JSPTabContainerProvider.

  • TemplateTabContainer - Creates a Desktop that contains multiple containers selected using different tabs. Normally, each tab is constructed by using TemplateTabCustomTableContainer, but you can use any container. This container is template-based. Its provider is TemplateTabContainerProvider.

  • TemplateTableContainer - Creates a Desktop that arranges a maximum of five sub-containers into the channel arrangement. This container is template-based. Its provider is TemplateTableContainerProvider.

When you install the sample portal, the default channel is set to JSPTabContainer. Users can view this portal by typing:

http://server:port/portal/dt

You can easily view each sample portal Desktop by typing in the appropriate URL. See "Accessing the Desktop," on page 38 for more information.

Sun ONE Portal Server determines the user's default container by examining the Default Channel Name attribute in the Desktop page, in the iPlanet™ Directory Server Access Management Edition admin console.

The container architecture uses the various containers, and JavaServer Pages™ (JSP™) or template files, to display the Desktop, and to build a hierarchy of containers that organize the Desktop content. Channels are defined at the global display profile level and are referenced by all the containers.

For more information on each container, see the appropriate section in this chapter.

Guidelines for Using the Sample Portal

Do not directly edit any of the files that make up the sample portal (display profile XML, JSP, and template files). Instead, make a copy of the sample portal to a new directory then modify those copied files. In this way you preserve the integrity of the sample portal. Additionally, if you later apply a patch to the portal server, you won't loose any changes you might have made to the sample portal files, as the patch would only overwrite the initially installed sample files.

You should also create a custom Desktop type for your users. For example, if the Desktop type were sesta, then you would create a /etc/opt/SUNWps/desktop/sesta directory to contain the template files that you have customized. You only need to copy the files that you have changed from the sample installation to the new directory tree. This structure enables you to tell at a glance which files have been modified from the original distribution. It also eliminates the need to back up copies of the original sample files.

Sample Portal Installation Directories

If you choose to install the sample portal, the installer locates the appropriate files in the following directories:

  • /opt/SUNWps/samples/desktop- Contains the following display profile documents:

    • dp-org.xml - Contains the display profile definitions for channels and containers.

    • dp-providers.xml - Contains the display profile definitions for providers.



      Note The dp-providers.xml display profile document is loaded at the o=isp level, because the provider definition most likely will not change.



    • dp-org-final.xml - Contains the display profile definitions for channels and containers and includes NetMail and NetMail Lite definitions.

    • dp-anon.xml - Contains the display profile definitions for channels and containers for the authlessanonymous user in the default organization.

  • /etc/opt/SUNWps/desktop/default and /etc/opt/SUNWps/desktop/anonymous - Contains the JSP, template, and other support files.

Desktop Theme Link

For the template-based containers, when you choose the Theme link, the look and feel of the toolbar changes slightly. (This is not the case for the JSP-based containers.) This happens because the template-based containers use JSPSingleContainer (which is a JSP-based container), and not a template-based container. Thus, the look and feel of the Theme page is "JSP," not "template."

JSP-based Tab Container (JSPTabContainer)

Figure 5-1 shows the JSP-based tab Desktop, JSPTabContainer, which provides a JSP-based tab container consisting of three tabs, My Front Page, Samples, and Search, and the following channels:

  • In the My Front Page tab: User Information, Sun ONE Information, My Bookmarks #2, Sample JSP, XML Test, Mailcheck Provider, My Bookmarks, and My Applications

  • In the Samples tab: Sun ONE Information, URL Scraper, Notes, and Pre-configured Web Service

  • In the Search tab: Search

Figure 5-1    JSP Tab-Based Desktop (JSPTabContainer)
The JSP tab-based container, showing three tabs: My Front Page, Samples, and Search

JSPTabContainer Architecture

Figure 5-2 shows the JSPTabContainer architecture. In this figure, tab.jsp is the top-level JSP file. The tab.jsp file makes include calls to the header.jsp, availableTabs.jsp, menubar.jsp, and footer.html files. The availableTabs.jsp file makes an include call to the selectedTab.jsp and tabs.jsp files.

See Appendix C, "JavaServer Pages Reference," more information on these JSP files.

JSPTabContainer is made up of three sub-containers, MyFrontPageTabPanelContainer, SamplesTabPanelContainer, and SearchTabPanelContainer, as represented by Tab1 (tablecontainer) in the figure.

Figure 5-2    JSPTabContainer Architecture
JSPTabContainer architecture, showing the container layout and associated JSP files.

JSPTabContainer Actions

This section describes the various actions that you can perform within JSPTabContainer.

Banner Links

  • Home - Returns you to the Desktop Home page from customization pages and updates content.

  • Tabs - Lets you remove, rename, or select the start tab, and also create a new tab. The link for this page is:

    action=edit&provider=JSPTabContainer

  • Theme - Lets you edit the Desktop theme. The theme enables you to set the color scheme and font type for the Desktop. You can choose from preset themes or make your own colors for a custom theme. The link for this page is:

    action=edit&provider=JSPPresetThemeContainer

    The custom theme channel is defined as a JSPSingleContainerProvider channel, and has an entry in the display profile. See "JSPSingleContainerProvider," on page 51 for more information.

  • Help - Displays the Desktop sample online help. The link for this page is:

    ../docs/locale/desktop/helppage.htm

  • Log Out - Logs you out from the Desktop. The link for this page is:

    action=logout

Links Specific to the Contained Container

The contained container for JSPTabContainer is the table container that is currently selected, for example, MyFrontPageTabPanelContainer.

Content and Layout Links

The top-most JSP in the table container defines the Content and Layout links. JSPContentContainer is the container that displays the Content page, and JSPLayoutContainer is the container that displays the Layout page. The following describes the actions for these pages:

  • Content - Lets you edit the content for this particular tab on the Content page. The link for this page, when the My Front Page tab is selected, is:

    action=edit&provider=JSPContentContainer&container=MyFrontPageTabPanelContainer&selected=My+Front+Page

  • Layout - Lets you edit the layout of the channels for this particular tab on the Layout page. The link for this page, when the My Front Page tab is selected, is:

    action=edit&provider=JSPLayoutContainer&container=MyFrontPageTabPanelContainer&selected=My+Front+Page

JSPTabContainer Edit Pages

When you click the Tabs link on the Content Page, the Current Tabs Settings Edit page appears, where you can make changes.

  • Start page - Lets you set the starting tab.

  • Rename - Lets you rename the tab. (JavaScript™ handles the action.)

  • Delete - Lets you delete a tab from the Desktop. (JavaScript handles the action.)

When you click Make a New Tab, the corresponding Edit page is shown. You decide what to name the tab and what the tab topics are. Clicking the Finished button renders the Content Page where channels can be selected for the new tab.

JSPTabContainerProvider Display Profile

The provider responsible for generating the JSPTabContainer channel is JSPTabContainerProvider. See "JSPTabContainerProvider," on page 50 for the display profile XML for this provider.

JSPTabContainer Channel Display Profile

The provider profile is the template which decides the properties for a container channel, but the container channel profile will ultimately decide the values for the container channel attributes. Code Example 5-1 shows the channel display profile for JSPTabContainer channel.



Code Example 5-1    Display Profile XML for JSPTabContainer Container Channel 
<Container name="JSPTabContainer" provider="JSPTabContainerProvider">
  <Properties>
  <String name="title" value="JSP Tab Container Channel"/>
  <String name="description" value="This is a test for tab containers"
  <String name="contentPage" value="tab.jsp"/>
  <String name="editPage" value="tabedit.jsp"/>
  <String name="startTab" value="MyFrontPageTabPanelContainer"/>
  <Integer name="maxTabs" value="4"/>
  <String name="makeTabProvider" value="JSPTabCustomTableContainerProvider" advanced="true"/>
  <String name="makeTabChannel" value="JSPTabCustomTableContainer" advanced="true"/>
  <Integer name="channelNumber" value="0"/>
  <String name="contentChannel" value="JSPContentContainer"/>

  <Collection name="TabProperties">
    <Collection name="MyFrontPageTabPanelContainer">
    <String name="title" value="My Front Page"/>
    <String name="desc" value="Your front page"/>
    <Boolean name="removable" value="false"/>
    <Boolean name="renamable" value="true"/>
    <Boolean name="predefined" value="true"/>
    </Collection>
    <Collection name="SamplesTabPanelContainer">
    <String name="title" value="Samples"/>
    <String name="desc" value="Sampless Tab"/>
    <Boolean name="removable" value="true"/>
    <Boolean name="renamable" value="true"/>
    <Boolean name="predefined" value="false"/>
    </Collection>
    <Collection name="SearchTabPanelContainer">
    <String name="title" value="Search"/>
    <String name="desc" value="Search Tab"/>
    <Boolean name="removable" value="true"/>
    <Boolean name="renamable" value="true"/>
    <Boolean name="predefined" value="true"/>
    </Collection>
  </Collection>

  <Collection name="defaultChannelList">
  <String value="UserInfo"/>
  <String value="MailCheck"/>
  <String value="App"/>
  <String value="SampleSimpleWebService"/>
  <String value="Bookmark"/>
  <String value="SampleJSP"/>
  <String value="SampleRSS"/>
  <String value="SampleXML"/>
  <String value="Notes"/>
  <String value="SampleURLScraper"/>
  <String value="Search"/>
  </Collection>
  <Collection name="propertiesToCopy">
  <String value="timeout"/>
  <String value="title"/>
  <String value="description"/>
  <String value="refreshTime"/>
  <String value="width"/>
  <String value="helpURL"/>
  <String value="fontFace1"/>
  <String value="productName"/>
  <String value="contentPage"/>
  <String value="layout"/>
  <String value="Desktop-fontFace1"/>
  <String value="isEditable"/>
  <String value="editType"/>
  <String value="presetThemeChannel"/>
  <String value="customThemeChannel"/>
  <String value="thin_popup_height"/>
  <String value="thin_popup_width"/>
  <String value="thick_popup_height"/>
  <String value="thick_popup_width"/>
  <String value="fullwidth_popup_height"/>
  <String value="fullwidth_popup_width"/>
  <String value="categories"/>
  <String value="defaultChannelIsMinimizable"/>
  <String value="defaultChannelIsMinimized"/>
  <String value="defaultChannelIsDetached"/>
  <String value="defaultChannelIsDetachable"/>
  <String value="defaultChannelIsRemovable"/>
  <String value="defaultChannelHasFrame"/>
  <String value="channelsIsMinimized"/>
  <String value="channelsHasFrame"/>
  <String value="channelsColumn"/>
  <String value="channelsRow"/>
  <String value="channelsIsMinimizable"/>
  <String value="channelsIsDetachable"/>
  <String value="channelsIsRemovable"/>
  <String value="channelsIsMovable"/>
  <String value="borderlessChannels"/>
  </Collection>

  </Properties>

  <Available>
  <Reference value="MyFrontPageTabPanelContainer"/>
  <Reference value="SamplesTabPanelContainer"/>
  <Reference value="SearchTabPanelContainer"/>
  </Available>

  <Selected>
  <Reference value="MyFrontPageTabPanelContainer"/>
  <Reference value="SamplesTabPanelContainer"/>
  <Reference value="SearchTabPanelContainer"/>
  </Selected>

  <Channels>
  </Channels>

</Container>


The properties that make up JSPTabContainer work as follows:

  • contentPage is set to tab.jsp. This draws the Content Page for the tab container.

  • editPage is set to tabedit.jsp. This displays the Edit page for the tab container where new tabs can be added, and existing tabs removed or renamed.

  • startTab sets the tab that opens first on the Desktop as MyFrontPageTabPanelContainer.

  • maxTabs allows four tabs to be created. As there are currently three tabs, one more can be added.

  • makeTabProvider specifies JSPTabCustomTableContainerProvider as the provider to create a new tab on the Desktop.

  • channelNumber specifies that a number is appended to a newly created tab as the channel name. This number is increased each time a new tab is created, so that the new tab will have unique name. For example, to create a new tab based on MyFrontPageTabPanelContainer in JSPTabContainer, the new tab channel name would be JSPTabContainer/MyFrontPageTabPanelContainer1. (The new tab name is actually the channelName property in the display profile plus the the value of channelNumber. channelNumber is incremented by one each time a new tab is created.)

  • contentChannel specifies JSPContentContainer as the content channel that provides the Content page displaying channels to add to a user-created tab.

  • The collection TabProperties has <Collection name=> entries for each of the three tabs that appear.

  • The collection defaultChannelList describes a list of channels that are included in the available and selected lists for a newly created tab.

  • The collection propertiesToCopy sets the initial properties to be defined in a newly created tab container.

  • The Available list describes all available channels for this container. The available channels are displayed in the Content Preference page for users to select from.

  • The Selected list describes selected channels for this container. Only selected channels shows up in the Desktop.

Contained Containers' Display Profile

The JSP tab container channel has MyFrontPageTabContainer, SamplesTabPanelContainer, and SearchTabPanelContainer as its contained channels. Code Example 5-2, Code Example 5-3, and Code Example 5-4 show the pertinent display profile.



Code Example 5-2    MyFrontPageTabContainer Display Profile  
<Container name="MyFrontPageTabPanelContainer" provider="JSPTableContainerProvider">
    <Properties>
    <String name="title" value="Front Table Container Channel"/>
    <String name="contentPage" value="tabtable.jsp"/>
    <String name="description" value="This is a test for front table containers"/>
    <String name="Desktop-fontFace1" value="Sans-serif"/>
    <Collection name="categories">
      <String value="Personal Channels"/>
      <String value="Sample Channels"/>
      <String value="News Channels"/>
    </Collection>
    <Collection name="Personal Channels">
      <String value="UserInfo"/>
      <String value="MailCheck"/>
      <String value="Bookmark"/>
      <String value="App"/>
    </Collection>
    <Collection name="Sample Channels">
      <String value="SampleJSP"/>
      <String value="SampleXML"/>
    </Collection>
    <Collection name="News Channels">
      <String value="SampleRSS"/>
    </Collection>
    <Collection name="channelsRow" advanced="true">
      <String name="MailCheck" value="4"/>
      <String name="App" value="5"/>
      <String name="Bookmark" value="3"/>
      <String name="SampleRSS" value="2"/>
      <String name="SampleXML" value="2"/>
    </Collection>
    <Collection name="channelsIsRemovable">
      <Boolean name="UserInfo" value="false"/>
    </Collection>

    </Properties>

    <Available>
      <Reference value="UserInfo"/>
      <Reference value="MailCheck"/>
      <Reference value="App"/>
      <Reference value="MyFrontPageTabPanelContainer/Bookmark2"/>
      <Reference value="SampleJSP"/>
      <Reference value="SampleRSS"/>
      <Reference value="SampleXML"/>
    </Available>

    <Selected>
      <Reference value="UserInfo"/>
      <Reference value="MailCheck"/>
      <Reference value="App"/>
      <Reference value="Bookmark"/>
      <Reference value="MyFrontPageTabPanelContainer/Bookmark2"/>
      <Reference value="SampleJSP"/>
      <Reference value="SampleRSS"/>
      <Reference value="SampleXML"/>
    </Selected>

  <Channels>
  <Channel name="Bookmark2" provider="BookmarkProvider">
       <Properties>
        <String name="title" value="My Bookmarks #2"/>
        <String name="refreshTime" value="600"/>
        <Collection name="targets">
          <String value="Sun home page|http://www.sun.com"/>
          <String value="Everything you want to know about Sun ONE ... |http://www.sun.com/software/products/portal_srvr/home_portal.html"/>
          <String value="Sun ONE home page|http://www.sun.com/software "/>
        </Collection>
      </Properties>
  </Channel>
  </Channels>
</Container>



Code Example 5-3    SamplesTabPanelContainer Display Profile  
<Container name="SamplesTabPanelContainer" provider="JSPTableContainerProvider">
  <Properties>
  <String name="title" value="Samples Container in the JSP Tab Desktop"/>
  <String name="contentPage" value="tabtable.jsp"/>
  <String name="description" value="This is a test for table containers"/>
  <Collection name="categories">
    <String value="Sample Channels"/>
  </Collection>
  <Collection name="Sample Channels">
    <String value="SampleRSS"/>
    <String value="SampleURLScraper"/>
    <String value="Notes"/>
    <String value="SampleSimpleWebService"/>
  </Collection>
  <Collection name="channelsColumn" advanced="true">
    <String name="SampleURLScraper" value="2"/>
    <String name="Notes" value="2"/>
    <String name="SampleSimpleWebService" value="2"/>
  </Collection>
  <Collection name="channelsRow" advanced="true">
    <String name="SampleURLScraper" value="2"/>
    <String name="Notes" value="3"/>
    <String name="SampleSimpleWebService" value="4"/>
  </Collection>

  </Properties>

  <Available>
  <Reference value="SampleRSS"/>
  <Reference value="SampleURLScraper"/>
  <Reference value="Notes"/>
  <Reference value="SampleSimpleWebService"/>
  </Available>

  <Selected>
  <Reference value="SampleRSS"/>
  <Reference value="SampleURLScraper"/>
  <Reference value="Notes"/>
  <Reference value="SampleSimpleWebService"/>
  </Selected>

  <Channels>
  </Channels>

</Container>




Code Example 5-4    SearchTabPanelContainer Display Profile  
<Container name="SearchTabPanelContainer" provider="JSPTableContainerProvider">
  <Properties>
  <String name="title" value="Search"/>
  <String name="contentPage" value="tabtable.jsp"/>
  <Integer name="timeout" value="120"/>
  <String name="description" value="This is the search tab "/>
  <Collection name="categories">
    <String value="Search Channels"/>
  </Collection>
  <Collection name="Search Channels">
    <String value="Search"/>
  </Collection>
  </Properties>

  <Available>
  <Reference value="Search"/>
  </Available>

  <Selected>
  <Reference value="Search"/>
  </Selected>

  <Channels>
  </Channels>
</Container>


JSP Files Used by JSPTabContainer

Sun ONE Portal Server uses JSP files for a channel's presentation layer. JSPTabContainer references two main JSPs, tab.jsp and tabedit.jsp, through the contentPage and editPage properties.

Content template is responsible for the front page of the container channel and the file name for the tab container channel is tab.jsp. The tab.jsp file extensively uses the Desktop taglibs. For more information on taglibs, see Appendix B, "JavaServer Pages Tag Library Reference."

The Edit page is where you can add, remove, and rename tabs. The tabedit.jsp is used to display this page. For a description of all JSP files used by JSPTabContainer, see Table C-15 on page 286.

JSP-based Table Container (JSPTableContainer)

Figure 5-3 shows the JSP-based table Desktop, JSPTableContainer, which provides a JSP-based table container consisting of the following channels:

  • Thin channels: User Information, Sun ONE Information, My Bookmarks, Mailcheck Provider, and My Applications

  • Wide channels: Sample JSP, XML Test, Notes, and Preconfigured Web Service

Figure 5-3    JSP Table-Based Desktop (JSPTableContainer)
The JSP table-based Desktop, showing the default thin-wide channel layout.

JSPTableContainer Architecture

Figure 5-4 shows the JSPTableContainer architecture. In this figure, toptable.jsp is the top-level JSP file. The toptable.jsp file makes include calls to the header.jsp, launchPopup.jsp, leafWrapper.jsp, and menubar.jsp files.

See Appendix C, "JavaServer Pages Reference," more information on these JSP files.

The default layout for JSPTableContainer is set to 1, which gives the thin-wide columns for the table. In Figure 5-4, Channels One, Two, and Three are thin channels, and Channels Four and Five are wide channels.

Figure 5-4    JSPTableContainer Architecture
JSPTableContainer architecture, showing the container layout and default arrangement of channels (thin-wide).

JSPTableContainer Actions

This section describes the various actions that you can perform within JSPTableContainer.

Banner Links

  • Home - Returns you to the Desktop Home page from customization pages and updates content.

  • Theme - Lets you edit the Desktop theme. The theme enables you to set the color scheme and font type for the Desktop. You can choose from preset themes or make your own colors for a custom theme. The link for this page is:

    action=edit&provider=JSPPresetThemeContainer

    The custom theme channel is defined as a JSPSingleContainerProvider channel, and has an entry in the display profile. See "JSPSingleContainerProvider," on page 51 for more information.

  • Log Out - Logs you out from the Desktop. The link for this page is:

    action=logout

  • Help - Displays the Desktop sample online help. The link for this page is:

    ../docs/locale/desktop/helppage.htm

Links Specific to the Contained Container

JSPTableContainer does not use a contained container.

Content and Layout Links

The toptable.jsp file defines the Content and Layout links. JSPContentContainer is the container that displays the Content page, and JSPLayoutContainer is the container that displays the Layout page. The following describes the actions for these pages:

  • Content - Lets you edit the content on the Content page. The link for this page is:

    action=edit&provider=JSPContentContainer&container=JSPTableContainer

  • Layout - Lets you edit the layout of the channels on the Layout page. The link for this page is:

    action=edit&provider=JSPLayoutContainer&container=JSPTableContainer

JSPTableContainerProvider Display Profile

The provider responsible for generating the JSPTableContainer channel is JSPTableContainerProvider. See "JSPTableContainerProvider," on page 48 for the display profile XML for this provider.

JSPTableContainer Channel Display Profile

The provider profile is the template which decides the properties for a container channel, but the container channel profile will ultimately decide the values for the container channel attributes. Code Example 5-5 shows the channel display profile for JSPTableContainer channel.



Code Example 5-5    JSPTableContainer Display Profile  
<Container name="JSPTableContainer" provider="JSPTableContainerProvider">
  <Properties>
  <String name="title" value="JSP Based Table Container Channel"/>
  <String name="contentPage" value="toptable.jsp"/>
  <String name="description" value="This is a test for front table containers"/>
  <String name="Desktop-fontFace1" value="Sans-serif"/>
  <Collection name="categories">
    <String value="Personal Channels"/>
    <String value="Sample Channels"/>
    <String value="News Channels"/>
  </Collection>
  <Collection name="Personal Channels">
    <String value="UserInfo"/>
    <String value="MailCheck"/>
    <String value="Bookmark"/>
    <String value="App"/>
  </Collection>
  <Collection name="Sample Channels">
    <String value="SampleSimpleWebService"/>
    <String value="SampleJSP"/>
    <String value="SampleXML"/>
  </Collection>
  <Collection name="News Channels">
    <String value="SampleRSS"/>
    <String value="Notes"/>
  </Collection>
  <Collection name="channelsRow" advanced="true">
    <String name="MailCheck" value="4"/>
    <String name="App" value="5"/>
    <String name="SampleSimpleWebService" value="6"/>
    <String name="Bookmark" value="3"/>
    <String name="SampleRSS" value="2"/>
    <String name="SampleXML" value="2"/>
    <String name="Notes" value="3"/>
  </Collection>
  <Collection name="channelsIsRemovable">
    <Boolean name="UserInfo" value="false"/>
  </Collection>
  </Properties>

  <Available>
    <Reference value="UserInfo"/>
    <Reference value="MailCheck"/>

    <Reference value="App"/>
    <Reference value="SampleSimpleWebService"/>
    <Reference value="Bookmark"/>
    <Reference value="SampleJSP"/>
    <Reference value="SampleRSS"/>
    <Reference value="SampleXML"/>
    <Reference value="Notes"/>
  </Available>

  <Selected>
    <Reference value="UserInfo"/>
    <Reference value="MailCheck"/>
    <Reference value="App"/>
    <Reference value="SampleSimpleWebService"/>
    <Reference value="Bookmark"/>
    <Reference value="SampleJSP"/>
    <Reference value="SampleRSS"/>
    <Reference value="SampleXML"/>
    <Reference value="Notes"/>
  </Selected>

  <Channels>
  </Channels>

</Container>


Container's Display Profile

The properties that make up JSPTableContainer work as follows:

  • contentPage is set to toptable.jsp. This draws the Content Page for the table container.

  • The collection categories defines the categories that appear in the Content page. Here there are three categories: Personal Channels, Sample Channels, and News Channels.

  • The collection channelsRow, and values that appear in this collection, contain the row number value for channels in this container. For example, the mail check channel is defined as row 4.

  • The collection channelsIsRemovable defines a collection to contain the isRemovable value for channels in this container. Only one channel, user information, is defined, with a value of false, so that it cannot be removed.

  • The Available list describes all available channels for this container. The available channels are displayed in the content preference page for users to select from.

  • The Selected list describes selected channels for this container. Only selected channels shows up in the Desktop.

JSP Files Used by JSPTableContainer

Sun ONE Portal Server uses JSP files for a channel's presentation layer. JSPTableContainer references one main JSPs, toptable.jsp, through the contentPage property.

Content template is responsible for the front page of the container channel and the file name for the tab container channel is toptable.jsp. The toptable.jsp file extensively uses the Desktop taglibs. For more information on taglibs, see Appendix B, "JavaServer Pages Tag Library Reference."

For a description of all JSP files used by JSPTabContainer, see Table C-18 on page 289.

Frame-based Container (FrameTabContainer)

Figure 5-5 shows the frame-based table Desktop, FrameTabContainer, which provides a frame-based table container consisting of two frames, My Front Page and Samples, with the following channels:

  • In the My Front Page frame: User Information, Sun ONE Information, My Bookmarks, Mailcheck Provider, My Applications, Sample JSP, and XML Test

  • In the Samples frame: Sun ONE Information, URL Scraper, Notes, and Preconfigured Web Service

Figure 5-5    Frame-Based Desktop (FrameTabContainer)
The frame-based Desktop, showing the initial page, My Front Page. The second page is accessed by the Samples link.

FrameTabContainer Architecture

Figure 5-6 shows the FrameTabContainer architecture. In this figure, frametab.jsp is the top-level JSP file. The frametab.jsp file makes include calls to the frametabmenu.jsp, header.jsp, banner.jsp, selectedTab.jsp, menubar.jsp, frameset.jsp, and footer.html files.

See Appendix C, "JavaServer Pages Reference," more information on these JSP files.

FrameTabContainer is made up of two sub-containers, MyFrontPageFramePanelContainer and SamplesFramePanelContainer, as represented by Page 1 (tablecontainer) in the figure.

Figure 5-6    FrameTabContainer Architecture
FrameTabContainer architecture, showing the container layout and associated JSP and HTML files.

FrameTabContainer Actions

This section describes the various actions that you can perform within FrameTabContainer.

Banner Links

  • Home - Returns you to the Desktop Home page from customization pages and updates content.

  • Sections - Lets you rename or select the start page, delete a page, and also create a new page. The link for this page is:

    action=edit&provider=FrameTabContainer

  • Theme - Lets you edit the Desktop theme. The theme enables you to set the color scheme and font type for the Desktop. You can choose from preset themes or make your own colors for a custom theme. The link for this page is:

    action=edit&provider=JSPPresetThemeContainer

    The custom theme channel is defined as a JSPSingleContainerProvider channel, and has an entry in the display profile. See "JSPSingleContainerProvider," on page 51 for more information.

  • Help - Displays the Desktop sample online help. The link for this page is:

    ../docs/locale/desktop/helppage.htm

  • Log Out - Logs you out from the Desktop. The link for this page is:

    action=logout

Links Specific to the Contained Container

The contained container for the FrameabContainer is JSPContentContainer.

Content and Layout Links

The top-most JSP in the table container defines the Content and Layout links. JSPContentContainer is the container that displays the Content page, and JSPLayoutContainer is the container that displays the Layout page. The following describes the actions for these pages:

  • Content - Lets you edit the content for this particular page on the Content page. The link for this page, when My Front Page is selected, is:

    action=edit&provider=JSPContentContainer&container=MyFrontPageFramePanelContainer

  • Layout - Lets you edit the layout of the channels for this particular page on the Layout page. The link for this page, when the My Front Page tab is selected, is:

    action=edit&provider=JSPLayoutContainer&container=MyFrontPageTabPanelContainer&selected=MyFrontPageFramePanelContainer

FrameTabContainer Edit Pages

When you click the Sections link on the Content page, the Current Page Settings Edit page appears, where you can make changes.

  • Start page - Lets you set the starting page.

  • Rename - Lets you rename the page. (JavaScript handles the action.)

  • Delete - Lets you delete a page from the Desktop. (JavaScript handles the action.)

When you click Make a New Page, the corresponding Edit page is shown. You decide what to name the page and what the page topics are. Clicking the Finished button renders the Content Page where channels can be selected for the new page.

JSPTabContainerProvider Display Profile

The provider responsible for generating FrameTabContainer channel is JSPTabContainerProvider. See "JSPTabContainerProvider," on page 50 for the display profile XML for this provider.

FrameTabContainer Channel Display Profile

The provider profile is the template which decides the properties for a container channel, but the container channel profile will ultimately decide the values for the container channel attributes. Code Example 5-6 shows the channel display profile for FrameTabContainer channel.



Code Example 5-6    FrameTabContainer Display Profile  
<Container name="FrameTabContainer" provider="JSPTabContainerProvider">
  <Properties>
  <String name="helpURL" value="desktop/fdesktop.htm" advanced="true"/>
  <String name="title" value="Framed Tab Container Channel"/>
  <String name="description" value="This is a test for frame containers"/>
  <String name="contentPage" value="frametab.jsp"/>
  <String name="editPage" value="frametabedit.jsp"/>
  <String name="startTab" value="MyFrontPageFramePanelContainer"/>
  <Integer name="maxTabs" value="4"/>
  <String name="makeTabProvider" value="JSPFrameCustomTableContainerProvider" advanced="true"/>
  <String name="makeTabChannel" value="FrameCustomTableContainer" advanced="true"/>
  <Integer name="channelNumber" value="0"/>
  <String name="contentChannel" value="JSPContentContainer"/>
  <Collection name="TabProperties">
    <Collection name="MyFrontPageFramePanelContainer">
    <String name="title" value="My Front Page"/>
    <String name="desc" value="Your front page"/>
    <Boolean name="removable" value="false"/>
    <Boolean name="renamable" value="true"/>
    <Boolean name="predefined" value="true"/>
    </Collection>
    <Collection name="SamplesFramePanelContainer">
    <String name="title" value="Samples"/>
    <String name="desc" value="Samples Page"/>
    <Boolean name="removable" value="true"/>
    <Boolean name="renamable" value="true"/>
    <Boolean name="predefined" value="true"/>
    </Collection>
    <Collection name="FrameCustomTableContainer">
    <String name="title" value="Make My Own Page"/>
    <String name="desc" value="Make from Scratch"/>
    <Boolean name="removable" value="true"/>
    <Boolean name="renamable" value="true"/>
    <Boolean name="predefined" value="false"/>
    </Collection>
  </Collection>

  <Collection name="defaultChannelList">
  <String value="UserInfo"/>
  <String value="MailCheck"/>
  <String value="App"/>
  <String value="SampleSimpleWebService"/>
  <String value="Bookmark"/>
  <String value="SampleJSP"/>
  <String value="SampleRSS"/>
  <String value="SampleXML"/>
  <String value="Notes"/>
  <String value="SampleURLScraper"/>
  </Collection>
  <Collection name="propertiesToCopy">
  <String value="timeout"/>
  <String value="title"/>
  <String value="description"/>
  <String value="refreshTime"/>
  <String value="width"/>
  <String value="helpURL"/>
  <String value="fontFace1"/>

  <String value="productName"/>
  <String value="contentPage"/>
  <String value="layout"/>
  <String value="Desktop-fontFace1"/>
  <String value="isEditable"/>
  <String value="editType"/>
  <String value="presetThemeChannel"/>
  <String value="customThemeChannel"/>
  <String value="thin_popup_height"/>
  <String value="thin_popup_width"/>
  <String value="thick_popup_height"/>
  <String value="thick_popup_width"/>
  <String value="fullwidth_popup_height"/>
  <String value="fullwidth_popup_width"/>
  <String value="categories"/>
  <String value="defaultChannelIsMinimizable"/>
  <String value="defaultChannelIsMinimized"/>
  <String value="defaultChannelIsDetached"/>
  <String value="defaultChannelIsDetachable"/>
  <String value="defaultChannelIsRemovable"/>
  <String value="defaultChannelHasFrame"/>
  <String value="defaultBorderlessChannel"/>
  <String value="channelsIsMinimized"/>
  <String value="channelsHasFrame"/>
  <String value="channelsColumn"/>
  <String value="channelsRow"/>
  <String value="channelsIsMinimizable"/>
  <String value="channelsIsDetachable"/>
  <String value="channelsIsDetached"/>
  <String value="channelsIsRemovable"/>
  <String value="channelsIsMovable"/>
  <String value="borderlessChannels"/>
  <String value="parentTabContainer"/>
  <String value="refreshParentContainerOnly"/>
  </Collection>

  </Properties>

  <Available>
  <Reference value="MyFrontPageFramePanelContainer"/>
  <Reference value="SamplesFramePanelContainer"/>
  </Available>

  <Selected>
  <Reference value="MyFrontPageFramePanelContainer"/>
  <Reference value="SamplesFramePanelContainer"/>
  </Selected>

  <Channels>
  </Channels>

</Container>


The properties that make up FrameTabContainer work as follows:

  • contentPage is set to frametab.jsp. This draws the Content Page for the frame container.

  • editPage is set to frametabedit.jsp. This displays the Edit page for the frame container where new pages can be added, or existing pages removed or renamed.

  • startTab sets the page that opens first on the Desktop as MyFrontPageFramePanelContainer.

  • maxTabs allows four pages to be created. As there are currently two pages, two more can be added.

  • makeTabProvider specifies JSPFrameCustomTableContainerProvider as the provider to create a new page on the Desktop.

  • channelNumber specifies that a number is appended to a newly created page as the channel name. This number is increased each time a new page is created, so that the new page will have unique name. For example, to create a new page based on MyFrontPageFramePanelContainer in FrameTabContainer, the new page channel name would be FrameTabContainer/MyFrontPageFramePanelContainer1. (The new page name is actually the channelName property in the display profile plus the the value of channelNumber. channelNumber is incremented by one each time a new page is created.)

  • contentChannel specifies JSPContentContainer as the content channel that provides the Content page displaying channels to add to a user-created page.

  • The collection TabProperties has <Collection name=> entries for each of the two pages that appear, and one for when a user creates a new page (FrameCustomTableContainer).

  • The collection defaultChannelList describes a list of channels that are included in the available and selected lists for a newly created page.

  • The collection propertiesToCopy specifies sets the initial properties to be defined in a newly created container.

  • The Available list describes all available channels for this container. The available channels are displayed in the content preference page for users to select from.

  • The Selected list describes selected channels for this container. Only selected channels shows up in the Desktop.

Contained Containers' Display Profile

The frame tab container channel has MyFrontPageFramePanelContainer and SamplesFramePanelContainer as its contained channels. Code Example 5-7 and Code Example 5-8 show the pertinent display profile.



Code Example 5-7    MyFrontPageFramePanelContainer Display Profile 
<Container name="MyFrontPageFramePanelContainer" provider="JSPTableContainerProvider">
  <Properties>
  <String name="title" value="My Front Page Container in the JSP Tab Deskt
op"/>
  <String name="description" value="This is a test for front table containers"/>
  <String name="Desktop-fontFace1" value="Sans-serif"/>
  <String name="parentTabContainer" value="FrameTabContainer" advanced="true"/>
  <Boolean name="refreshParentContainerOnly" value="true" advanced="true"/>
  <Collection name="categories">
    <String value="Personal Channels"/>
    <String value="Sample Channels"/>
    <String value="News Channels"/>
  </Collection>
  <Collection name="Personal Channels">
    <String value="UserInfo"/>
    <String value="MailCheck"/>
    <String value="Bookmark"/>
    <String value="App"/>
  </Collection>
  <Collection name="Sample Channels">
    <String value="SampleJSP"/>
    <String value="SampleXML"/>
  </Collection>
  <Collection name="News Channels">
    <String value="SampleRSS"/>
  </Collection>
  <Collection name="channelsRow" advanced="true">
    <String name="MailCheck" value="4"/>
    <String name="App" value="5"/>
    <String name="Bookmark" value="3"/>
    <String name="SampleRSS" value="2"/>
    <String name="SampleXML" value="2"/>
  </Collection>
  <Collection name="channelsIsRemovable">
    <Boolean name="UserInfo" value="false"/>
  </Collection>
  </Properties>

  <Available>
    <Reference value="UserInfo"/>
    <Reference value="MailCheck"/>

    <Reference value="App"/>
    <Reference value="Bookmark"/>
    <Reference value="SampleJSP"/>
    <Reference value="SampleRSS"/>
    <Reference value="SampleXML"/>
  </Available>

  <Selected>
    <Reference value="UserInfo"/>
    <Reference value="MailCheck"/>
    <Reference value="App"/>
    <Reference value="Bookmark"/>
    <Reference value="SampleJSP"/>
    <Reference value="SampleRSS"/>
    <Reference value="SampleXML"/>
  </Selected>

  <Channels>
  </Channels>

</Container>




Code Example 5-8    SamplesFramePanelContainer Display Profile  
<Container name="SamplesFramePanelContainer" provider="JSPTableContainerProvider">
  <Properties>
  <String name="title" value="Table Container Channel4"/>
  <String name="contentPage" value="table.jsp"/>
  <String name="description" value="This is a test for table containers"/>
  <String name="parentTabContainer" value="FrameTabContainer" advanced="true"/>
  <Boolean name="refreshParentContainerOnly" value="true" advanced="true"/>
  <Collection name="categories">
    <String value="Sample Channels"/>
  <Collection name="Sample Channels">
    <String value="SampleRSS"/>
    <String value="SampleURLScraper"/>
    <String value="Notes"/>
    <String value="SampleSimpleWebService"/>
  </Collection>
  <Collection name="channelsColumn" advanced="true">
    <String name="SampleURLScraper" value="2"/>
    <String name="Notes" value="2"/>
    <String name="SampleSimpleWebService" value="2"/>
  </Collection>
  <Collection name="channelsRow" advanced="true">
    <String name="SampleURLScraper" value="2"/>

    <String name="Notes" value="3"/>
    <String name="SampleSimpleWebService" value="3"/>
  </Collection>

  </Properties>

  <Available>
  <Reference value="SampleRSS"/>
  <Reference value="SampleURLScraper"/>
  <Reference value="Notes"/>
  <Reference value="SampleSimpleWebSng name="Notes" value="3"/>
  </Available>

  <Selected>
  <Reference value="SampleRSS"/>
  <Reference value="SampleURLScraper"/>
  <Reference value="Notes"/>
  <Reference value="SampleSimpleWebService"/>
  </Selected>

  <Channels>
  </Channels>

</Container>


JSP Files Used by FrameTabContainer

Sun ONE Portal Server uses JSP files for a channel's presentation layer. FrameTabContainer references two main JSPs, frametab.jsp and frametabedit.jsp, through the contentPage and editPage properties.

Content template is responsible for the front page of the container channel and the file name for the tab container channel is frametab.jsp. The frametab.jsp file extensively uses the Desktop taglibs. For more information on taglibs, see Appendix B, "JavaServer Pages Tag Library Reference."

The Edit page is where you can add, remove, and rename pages. The frametabedit.jsp is used to display this page. For a description of all JSP files used by FrameTabContainer, see Table C-4 on page 280.

Template-based Containers (TemplateTabContainer and TemplateTableContainer)

TemplateTabContainer and TemplateTableContainer use the original template mechanism from iPlanet™ Portal Server 3.0. TemplateTableContainer is the same as the normal Desktop from iPlanet Portal Server 3.0, and TemplateTabContainer is the same as the tabbed Desktop from iPlanet Portal Server 3.0. You use these containers for migrating from existing iPlanet Portal Server 3.0 (Service Pack 3a or 4) custom Desktops to Sun ONE Portal Server 6.0.

See Chapter 5, "Migrating the Desktop," in the Sun ONE Portal Server 6.0 Migration Guide for more information.


Previous     Contents     Index     Next     
Copyright 2002 Sun Microsystems, Inc. All rights reserved.

Last Updated August 30, 2002