ICEfaces Component Suite


Standard Syntax:
     <%@ taglib prefix="ice" uri="http://www.icesoft.com/icefaces/component" %>

XML Syntax:
     <anyxmlelement xmlns:ice="http://www.icesoft.com/icefaces/component" />

No Description

Tag Library Information
Display NameICEfaces Component Suite
Version1.8.1
Short Nameice
URIhttp://www.icesoft.com/icefaces/component
 

Tag Summary
effect Add effects to parent component
panelBorder

The panelBorder is a layout container component that arranges and resizes specified child containers to fit in five regions: north, south, east, west, and center. These regions are defined using facets.
The panelBorder component can be used to provide a general layout scheme for a page.
Note: A panelBorder facet needs a container type component as a child (e.g., panelGroup, panelGrid or form). panelGroup renders a span tag, which doesn't work properly if using Mozilla. panelGrid can be used to avoid display problems.

column

Renders a UIComponent that represents a single column of data within a parent UIData component.

columnGroup

To get the multiple dataTable headers or footers with allowable colspan and rowspan, you need to use the columnGroup component inside the "header" or the "footer" facet of the ice:dataTable component.

The "facet" can have a single child only, so one columGroup is required inside the facet. The ice:headerRow component is a valid child of the columnGroup component.

<ice:dataTable .. >
<f:facet name="header">
  <ice:columnGroup>
    <ice:headerRow>
      <ice:column rowspan="2">
        <ice:outputText value="First Name"/>
      </ice:column>
      <ice:column rowspan="2">
        <ice:outputText value="Last Name"/>
      </ice:column>
      <ice:column colspan="2">
        <ice:outputText value="Contact Info"/>
      </ice:column>
    </ice:headerRow>
    <ice:headerRow>
      <ice:column>
        <ice:outputText value="Phone"/>
      </ice:column>
      <ice:column>
        <ice:outputText value="Email"/>
      </ice:column>
    </ice:headerRow>
  </ice:columnGroup>
</f:facet>
<ice:column>
<ice:outputText id="firstName" value="#{person.firstName}"/>
</ice:colum>
.....
</ice:dataTable .. >

columns

The difference between the UIColumns and the UIColumn is that the UIColumn renders just a single "td" element, while the UIColumns can render as much TDs as the length of the dataModel.
Like the data table the datamodel can be used through the vale and var attributes.

dataExporter

The ice:dataExporter component can be used to export the data contents of an ice:dataTable component into a variety of formats.
There are following two formats supported by the component:

  • Excel
  • CSV
The outputTypeHandler attribute allows developer to define custom output formats.
The label, image and renderLabelAsButton are interrelated. Their order of precedence are as follows:
  • If image URL is specified, the label text will become the alt text for the image, the image is a clickable anchor to trigger the export operation. This supercedes the following two configurations.
  • If renderLabelAsButton=true, the label text will used for a rendered button that will trigger the export operation.
  • (default) The label text is rendered as an anchor which, when clicked, will trigger the export operation.

dataPaginator

The dataPaginator component is used in conjunction with a dataTable. The dataPaginator may be used to render a set of page navigation facets and access attributes of the underlying DataModel specified in the associated dataTable. Using the dataPaginator, a dataTable containing a large DataModel can be viewed as multiple "pages" of table rows instead of as one large table.
The dataPaginator component can be used to provide a more manageable, performant view into a large DataModel.

inputFile

The inputFile component can be used to provide a user-specified file upload capability.
The inputFile component renders an file input HTML element. Users specify a file to upload either by entering the path to a file directly, or by clicking the Browse button to open a file-system navigation dialog window. Clicking the Upload button uploads the specified file to the server.
Note: Newer browsers now make the field, where users previously could type in the file path, be read-only, to prevent users from entering invalid file paths. Clicking into that field can summon the file selection dialog, just as clicking on the Browse button would.
Note: The web.xml parameter com.icesoft.faces.uploadDirectoryAbsolute when set to true will use the value of the com.icesoft.faces.uploadDirectory parameter as an absolute directory.
Note: If the styleClass, buttonClass or the inputTextClass need to be set, then the css file must be referenced using the ice:outputStyle component.
Note: In order to set the height and width of this component, it is recomended to use the height and the width attribute of this component instead of setting it using the style or styleClass. This is due to the rendering of an iframe.

gMap This component uses the version 2 of the Google Maps API. In order to use the google maps, an API key is required. The API key can be obtained from the google maps' website. You must need to specify the API key in the web.xml(e.g.)
<context-param>
   <param-name>com.icesoft.faces.gmapKey</param-name>
   <param-value>ABQIAAAADlu0Z........</param-value>
</context-param>
gMapControl This component adds the control to the ice:gMap. This component must need to be a child of ice:gMap component. (e.g.)
<ice:gMap>
<ice:gMapControl name="GLargeMapControl"/>
<ice:gMapControl name="GScaleControl"/>
</ice:gMap>
gMapDirection The gMapDirection component uses the google map's GDirections API to get the direction from point A to point B. This component must need to be a child of ice:gMap component.
gMapGeoXml This component uses google map's GGeoXml API, to support the KML and GeoRSS data formats for displaying geographic information.
<ice:gMap latitude="41.875696" longitude="-87.624207" zoomLevel="11">
   <ice:gMapGeoXml url="http://mapgadgets.googlepages.com/cta.kml"/>
</ice:gMap>
gMapLatLng This component is a wrapper of google map's GLatLng API. Can be child of gMapMarker component.
gMapLatLngs This component can be a child of gMapMarker component and its value attribute can be a list of gMapLatLng component.
gMapMarker This component uses the google map's GMarker API, which displays the points on the map.
To define the marker the "longitude" and the "latitude" attributes of this component can be used (e.g.)

<ice:gMap>
  <ice:gMapMarker latitude="51" longitude="-90"/>
</ice:gMap>

In addition to that the "gMapLatLng" and "gMapLatLngs" components can be used as its children (e.g.)
<ice:gMap>
    <ice:gMapMarker latitude="51" longitude="-90">
      <ice:gMapLatLng latitude="51.067591" longitude="-114.084862"/>
      <ice:gMapLatLngs value="#{gmap.points}"/>
  </ice:gMapMarker>
</ice:gMap>
headerRow

This component represents a single header row. The ice:column is its valid children.

<ice:dataTable .. >
<f:facet name="header">
  <ice:columnGroup>
    <ice:headerRow>
      <ice:column rowspan="2">
        <ice:outputText value="First Name"/>
      </ice:column>
      <ice:column rowspan="2">
        <ice:outputText value="Last Name"/>
      </ice:column>
      <ice:column colspan="2">
        <ice:outputText value="Contact Info"/>
      </ice:column>
    </ice:headerRow>
    <ice:headerRow>
      <ice:column>
        <ice:outputText value="Phone"/>
      </ice:column>
      <ice:column>
        <ice:outputText value="Email"/>
      </ice:column>
    </ice:headerRow>
  </ice:columnGroup>
</f:facet>
<ice:column>
<ice:outputText id="firstName" value="#{person.firstName}"/>
</ice:colum>
.....
</ice:dataTable .. >

checkbox

Render a checkbox for a selectManyCheckbox component when the layout of the selectManyCheckbox component is "spread".

commandButton

Renders an HTML "input" element.

Decode Behavior

    Obtain the Map from the "requestParameterMap" property of the ExternalContext. If the value in the Map for the value of the "clientId" property of the component is null, create a String by concatenating the value of the "clientId" property of the component with the String ".x" (without the quotes). Create another String in the same manner, but concatenate ".y" (without the quotes). If null is the value in the Map for both Strings, return from decode(). If the value in the Map for the value of the "clientId" property of the component is not null, get the value of the "type" attribute, and convert it to lower case. If the result is equal to the String "reset" (without the quotes), return from decode(). Otherwise, create a javax.faces.event.ActionEvent around the component, and pass it to the queueEvent() method of the component, which must be an instance of UICommand.

Encode Behavior

    Render the clientId of the component as the value of the "name" attribute. Render the current value of the component as the value of the "value" attribute. If the "styleClass" attribute is specified, render its value as the value of the "class" attribute.

commandLink

Render an HTML "a" anchor element that acts like a form submit button when clicked.

General Behaviour

Both the encode and decode behavior require the ability to get the id/name for a hidden field whose value is set by the JavaScript form submit. This name must be constructed as follows:

  • Get the clientId for the form of which this component is a child.

  • Append NamingContainer.SEPARATOR_CHAR.

  • Append a constant string that is the same for all command link components in the tree.

In the following text, this String is called hiddenFieldName.

Decode Behavior

    Obtain the "clientId" property of the component. Obtain the Map from the "requestParameterMap" property of the ExternalContext. Derive hiddenFieldName as above. Get the entry in the Map under the key that is the hiddenFieldName. If the there is no entry, or the entry is the empty String, or the entry is not equal to the value of the "clientId" property, return immediately. If there is an entry, and its value is equal to the value of the "clientId" property, create a new javax.faces.event.ActionEvent instance around the component and call queueActionEvent() on the component, passing the event.

Encode Behavior

    Render "#" as the value of the "href" attribute. Render the current value of the component as the link text if it is specified. Render javascript that is functionally equivalent to the following as the value of the "onclick" attribute:

    document.forms['CLIENT_ID']['hiddenFieldName'].value='CLIENT_ID'; document.forms['CLIENT_ID']['PARAM1_NAME'].value='PARAM1_VALUE'; document.forms['CLIENT_ID']['PARAM2_NAME'].value='PARAM2_VALUE'; return false;

    document.forms['CLIENT_ID'].submit()" where hiddenFieldName is as described above, CLIENT_ID is the clientId of the UICommand component, PARAM*_NAME and PARAM*_VALUE are the names and values, respectively, of any nested UIParameter children. The name and the value must be URLEncoded. If the "styleClass" attribute is specified, render its value as the value of the "class" attribute. Render any non-UIParameter children as normal inside of the "a" element. These will appear as the link text. Allow the form renderer to output a single "input" element (for the entire page, regardless of how many command link components are in the page) of "type" "hidden" whose "name" is the value of hiddenFieldName, and which must not have a "value" attribute. Multiple occurrences of command link components in the tree should not cause multiple hiddenFieldName hidden fields. Allow the form renderer to output an "input" element of "type" "hidden" for each of the nested UIParameter children, taking the name property (but not the value) from each one in turn.

dataTable

Renders an HTML "table" element compliant with the HTML 401 specification. Please consult the javadoc for UIData to supplement this specification. If the "styleClass" attribute is specified, render its value as the value of the "class" attribute on the "table" element. Any pass-through attributes are also rendered on the "table" element.

Rendering the header

    If the UIData component has a "header" facet, or any of the child UIColumn components has a "header" facet, render a "thead" element. If the UIData component has a "header" facet, encode its contents inside of "tr" and "th" elements, respectively. Output the value of the "headerClass" attribute of the UIData component, if present, as the value of the "class" attribute on the "th". Output the number of child UIColumn components of the UIData component as the value of the "colspan" attribute on the "th". Output "colgroup" as the value of the "scope" attribute on the "th" element.

    If any of the child UIColumn components has a "header" facet render a "tr" element. For each UIColumn that actually has a "header" facet, render it inside of a "th" element. Columns that don't have a "header" facet cause an empty "th" element to be rendered. Output the value of the "headerClass" attribute of the UIData component, if present, as the value of the "class" attribute on the "th". Output "col" as the value of the "colgroup" attribute on the "th" element.

    Close out the "thead" element.

Rendering the footer

    Follow the same process as for the header, except replace "header" with "footer", "th" with "td", "thead" with "tfoot", and "headerClass" with "footerClass". Do not render any "scope" attribute for the footer.

Rendering the table body

    Render a "tbody" element. Keep track of the result of the "rows" property on the UIData component. Keep track of the number of rows we have rendered so far. Iterate through the rows. Set the "rowIndex" property of the UIData component to be correct as we iterate through the rows. Stop rendering children and close out the "tbody" element if the "rowAvailable" property of the UIData returned false. Output a "tr" element. Output the value of the "rowClasses" per the attribute description below. For each UIColumn child, output a "td" element, attaching the value of the "columnClasses" attribute of the UIData component per the attribute description below. Recursively encode each child of each UIColumn child. Close out the "td" element. When done with the row, close out the "tr" element. When done with all the rows, close out the "tbody" element.

When done rendering all the rows, set the "rowIndex" property of the UIData to -1, and close out the "table" element.

form

Renders an HTML "form" element.

Decode Behavior

    Obtain the Map from the "requestParameterMap" property of the ExternalContext. If the map contains an entry for the "clientId" of this UIForm component, call setSubmitted(true) on the form, otherwise call setSubmitted(false) on the form.

Encode Behavior

    The value of the "method" attribute must be "post". The value of the "action" attribute must be the result of passing the view identifier of the current view to the getActionURL() method of the ViewHandler for this application, then passing that String to the encodeActionURL() method on the ExternalContext. If the "styleClass" attribute is specified, render its value as the value of the "class" attribute. Render all the necessary hidden fields for all commandLink instances in the page just before the close of the "form" element.

graphicImage Renders an HTML "img" element. Render the clientId as the value of the "id" attribute. Render the value of the component as the value of the "src" attribute, after passing it to the getResourceURL() method of the ViewHandler for this application, and passing the result through the encodeResourceURL() method of the ExternalContext. If present, render the value of the alt attribute as the value of the "alt" attribute. If the "styleClass" attribute is specified, render its value as the value of the "class" attribute.
inputHidden

Renders an HTML "input" element of "type" "hidden".

Decode Behavior

    Obtain the Map from the "requestParameterMap" property of the ExternalContext. If the Map contains an entry for the "clientId" of the component, pass the value of the entry to the setSubmittedValue() method of the component, which must be an instance of EditableValueHolder.

Encode Behavior

    Render the clientId of the component as the value of the "name" attribute. Render the current value of the component as the value of the "value" attribute.

inputSecret

Renders an HTML "input" element of "type" "password".

Decode Behavior

    See the decode description for the Input Text renderer.

Encode Behavior

    Render the clientId of the component as the value of the "name" attribute. Render the current value of the component as the value of the "value" attribute, if and only if the "redisplay" component attribute is the string "true". If the "styleClass" attribute is specified, render its value as the value of the "class" attribute.

inputText

Renders an HTML "input" element of "type" "text".

Decode Behavior

    Obtain the Map from the "requestParameterMap" property of the ExternalContext. If the Map contains an entry for the "clientId" of the component, pass the value of the entry to the setSubmittedValue() method of the component, which must be an instance of EditableValueHolder.

Encode Behavior

    Render the clientId of the component as the value of the "name" attribute. Render the current value of the component as the value of the "value" attribute. If the "styleClass" attribute is specified, render its value as the value of the "class" attribute.

inputTextarea

Renders an HTML "textarea" element.

Decode Behavior

    See the encode description for the Input Text renderer.

Encode Behavior

    Render the clientId as the value of the "name" attribute. Render the current value of the component inside the "textarea" element.

message

Render a single message for a specific component.

Set-up for Rendering

    Obtain the "summary" and "detail" properties from UIMessage component. If not present, keep the empty string as the value, respectively. Obtain the first FacesMessage to render from the component, using the "for" property of the UIMessage. This will be the only message we render. Obtain the severity style for this message. If the severity of the message is FacesMessage.SEVERITY_INFO, the severity style comes from the value of the "infoStyle" attribute. If the severity of the message is FacesMessage.SEVERITY_WARN, the severity style comes from the value of the "warnStyle" attribute, and so on for each of the severities, INFO, WARN, ERROR and FATAL. The same rules apply for obtaining the severity style class, but instead of "infoStyle, warnStyle", etc use "infoClass, warnClass", etc. Obtain the "style", "styleClass" and "layout" attributes from the UIMessage component. If we have a "style" attribute and a severity style attribute, use the severity style attribute as the value of the "style" attribute. If we have no "style" attribute, but do have a severity style, use the severity style as the value of the "style" attribute. The same precedence rules apply for the style class.

Rendering

    For the message renderer, we only render one row, for the first message. For the messages renderer, we render as many rows as we have messages. If either of the "style" or "styleClass" attributes has a non-null value (as determined above), render a "span" element, outputting the value of the "style" attribute as the the value of the "style" attribute, and outputting the value of the "styleClass" attribute as the value of the "class" attribute on the "span" element. If the UIMessage has a "tooltip" attribute with the value of "true", and the UIMessage has "showSummary" and "showDetail" properties with the value "true", if we haven't already written out the "span", output the "summary" as the value of the "title" attribute on the "span". If we haven't already written out a "title" attribute, and "showSummary" is true, output the summary. If "showDetail" is true, output the detail. Close out the span if necessary.

messages

The same as for the Message renderer, but output all the messages. If the value of the "layout" attribute is "table", render nested "table", "tr", and "td" elements, in that order, otherwise, don't render the table. The component is a UIMessages, and there is no "for" attribute. Therefore, use either null to obtain the messages from the FacesContext or the empty string if the components "globalOnly" property is true. If the layout was "table" close out the table elements.

outputFormat

Render parameterized text. Obtain the style and styleClass attributees from this component. If either are present, render a "span" element. Output the styleClass attribute (if present) as the value of the class attribute. Output the style attribute as the value of the style attribute. Accrue a list of the values of all child UIParameter components of this component. If there are one or more accumulated parameter values, convert the list of parameter values to an Object array, call MessageFormat.format(), passing the value of this component as the first argument, and the array of parameter values as the second argument, and render the result. Otherwise, render the value of this component unmodified.

outputLabel

Renders an HTML "label" element. Render the current value of the component as label text if it is specified. If a "for" attribute is specified, find the component specified by the value of the "for" attribute, and render its client id as the value of the "for" attribute. If "styleClass" attribute is specified, render its value as the value of the "class" attribute.

outputLink Render an HTML "a" anchor element. The value of the component is rendered as the value of the "href" attribute. Any child UIParameter components are appended to the String to be output as the value of the "href" attribute as query parameters before rendering. The entire "href" string must be passed through a call to the encodeResourceURL() method of the ExternalContext. The name of the UIParameter goes on the left hand side, and the value of the UIParameter on the right hand side. The name and the value must be URLEncoded. Each UIParameter instance is separated by an ampersand, as dictated in the URL spec. If the "styleClass" attribute is specified, render its value as the value of the "class" attribute.
outputText If the "styleClass" or "style" attributes are present, render a "span" element. If the "styleClass" attribute is present, render its value as the value of the "class" attribute. If the "style" attribute is present, pass it thru. If the "escape" attribute is not present, or it is present and its value is "true" all angle brackets should be converted to the ampersand xx semicolon syntax when rendering the value of the "value" attribute as the value of the component. If the "escape" attribute is present and is "false" the value of the component should be rendered as text without escaping.
panelGrid Renders an HTML "table" element, conforming to the rules in the HTML 401 specification. If the "styleClass" attribute is specified, render its value as the value of the "class" attribute. Render the pass-through attributes in the table below. Render the "header" facet, if present, inside of "thead", "tr", and "th" elements, nested in that order. If the "headerClass" attribute is specified, render its value as the value of the "class" attribute on the "th" element. Render "colgroup" as the value of the "scope" attribute. Render the value of the "columns" attribute as the value of the "colspan" attribute on the "th" element. Render the "footer" facet if present, using similar logic to the rendering of the "header", but replacing "thead" with "tfoot", "th" with "td", and "headerClass" with "footerClass". Render the children of the UIPanel component inside of a "tbody" element. Render the children based on the value of the "columns" attribute, creating a new row each time a "columns" worth of children have been rendered. Each child is rendered inside of a "td" element. If a child has "rendered==false" it is not rendered, and the column counter must not be incremented.
panelGroup

The panelGroup component is intended for use in situations when only one UIComponent child can be nested, such as in the case of facets. The panelGroup component renders a "div" element around it's child components, outputting the value of the "style" attribute as the value of the "style" attribute, and the value of the "styleClass" attribute as the value of the "class" attribute.

The panelGroup can also provide Drag & Drop functionality to it's child components. See the Drag & Drop documentation details.

The panelGroup component can also be used to apply a single Effect (Fade, Show, etc.) to a set of child-components by adding the components to the panelGroup and specifying the effect on the panelGroup "effect" attribute.

Note: The "position" property of the container div must need to be set to the "relative", if its "overflow" property of the css is set to "auto" or "scroll" and all the draggable panelGroups inside the container div must be using the dragOptions="dragGhost".
radio

Render a radio button for the selectOneRadio component when the layout of the selectOneRadio component is "spread".

selectBooleanCheckbox

Renders an HTML "input" element of type "checkbox".

Decode Behavior

    Obtain the Map from the "requestParameterMap" property of the ExternalContext. If there is no entry in the Map for the "clientId" of this component, pass "false" to the setSubmittedValue() method of the component, which must be an instance of EditableValueHolder. If there is an entry, and its value is equal, ignoring case and without quotes, to any of the Strings: "on", "yes" or "true" pass true to the setSubmittedValue() method of the component.

Encode Behavior

    Render the clientId of the component as the value of the "name" attribute. If the current value of the component is "true", output the "checked" attribute. If the "styleClass" attribute is specified, render its value as the value of the "class" attribute.

selectManyCheckbox

Render an HTML checkbox list.

Decode Behavior

Encode Behavior

    Render a "table" element. If the "styleClass" is specified, render the value of the "styleClass" attribute as the value of the "class" attribute on the "table" element. If the "style", "border" attributes are specified, pass them thru. If the "layout" attribute is specified, and its value is "spread", let the checkbox tag do the rendering. If the "layout" attribute is specified, and its value is "pageDirection", render the children elements vertically, otherwise horizontally, in the table. If any of the children are an instance of SelectItemGroup, render them as a nested table. Each of the children are ultimately rendered as follows. Render a "label" element. Inside of the "label", render an "input" element of "type" "checkbox" for each child component. As an exception to the general rules about how to handle the "id" attribute, render it as an attribute on the outer "table" element, the value of which is the clientId of the component per the rules at the beginning of this specification.The "id" attribute must not be output on each "input" element. The value of the current SelectItem is rendered as the value of the "value" attribute. If the value of the enclosing UISelectMany matches the current value, render "checked" as the value of the "checked" attribute. If the current SelectItem.isDisabled() returns true, render "disabled" as the value of the "disabled" attribute. Close out the "input" element and render the return value from SelectItem.getLabel(). Close out the "label" element and any other nested elements. See the "Rendering the option elements" specification for ListboxRenderer for more detail on how to render the "option" elements in this renderer.

selectManyListbox

Render an HTML option list.

Decode Behavior

This section documents the decode behavior for all renderers that handle UISelectMany or UISelectOne components.

    Decode Behavior for UISelectMany components

      Obtain the Map from the "requestParameterValuesMap" property of the ExternalContext. If the Map contains an entry for the "clientId" of the component, pass the value of the entry, cast to a String [], to the setSubmittedValue() method of the component, which must be an EditableValueHolder. If the Map does not contain an entry, create an empty String array and call setSubmittedValue() with it.

    Decode Behavior for UISelectOne components

      Obtain the Map from the "requestParameterMap" property of the ExternalContext. If there is a Map entry for the "clientId" property of the component, pass it to the setSubmittedValue() method of the component.

    Encode Behavior

      Render an HTML "select" element. Render the clientId of the component as the value of the "name" attribute. If the "styleClass" attribute is specified, render its value as the value of the "class" attribute on the "select" element. If the component is a UISelectMany instance, render "multiple" as the value of the "multiple" attribute. If the "size" attribute is specified, render its value as the value of the "size" attribute. Otherwise use the number of items as the value of the "size" attribute.

    Rendering the "option" elements

      The only valid children of this component are UISelectItem or UISelectItems instances. Iterate over the children of this component, and accrue a list of javax.faces.model.SelectItem instances. If the current child is a UISelectItem create a SelectIteminstance from its itemValue, itemLabel and itemDescription properties, add it to the list. If the current child is a UISelectItems instance, call its getValue() method. If the result is a SelectItem bean, add it to the list. If the result is an array of SelectItem beans, add each one t othe list. If the result is a Collection of SelectItem beans, add each one to the list. If the result isa Map, create a SelectItem bean for each entry in the Map using the key as the label, the value as the value, and null as the description. Iterate over the list of SelectItem beans. If the current element is a SelectItemGroup, render an "optgroup" element with a "label" attribute, the value of which is the "label" property from the current element, then call getSelectItems() and render each element as below. If the current element is not a SelectItemGroup, render an "option" element. Follow the conversion rules in the spec to obtain a renderable String from the "value" property of the current element, render that as the value of the "value" atribute. Now it is time to see if the current element is the selected value. call its getSubmittedValue() method, casting the result to an Object [], otherwise the component must be a UISelectOne instance, call its getSubmittedValue() method and create an Object [] around the result. If the resultant array is non-null, we look in the array for a value that, when we pass the renderable value to its equals() method, it returns true, meaning the current element is selected. If the resultant array is null, if the component is a UISelectMany, call its getValue() method. If the result is a List obtain the values in the list as an array. Otherwise, the component must be a UISelectOne instance. Call its getValue() method, which must be an Object array. Look for an element in the resultant array that, 1. when we pass the renderable value to its equals() method, it returns true , or 2. if the renderable value is null, and there is a null element in the array, also conclude that the current element is selected. Otherwise the current element is not selected. Now, if the current value is selected, write out an HTML boolean property "selected". If the current SelectItem.isDisabled() returns true, render "disabled" as the value of the "disabled" attribute.

selectManyMenu

Render an HTML option list.

Decode Behavior

Encode Behavior

    Render an HTML "select" element. Render the clientId of the component as the value of the "name" attribute. If the "styleClass" attribute is specified, render its value as the value of the "class" attribute on the "select" element. If the component to be rendered is a UISelectMany, render "true" as the value of the "multiple" attribute. Render "1" as the value of the "size" attribute. See the "Rendering the option elements" specification for ListboxRenderer for more detail on how to render the "option" elements in this renderer.

selectOneListbox

Render an HTML option list.

Decode Behavior

Encode Behavior

    Render an HTML "select" element. Render the clientId of the component as the value of the "name" attribute. If the "styleClass" attribute is specified, render its value as the value of the "class" attribute on the "select" element. If the component to be rendered is a UISelectMany, render "true" as the value of the "multiple" attribute. If the "size" attribute is specified, render its value as the value of the "size" attribute. Otherwise use the number of items as the value of the "size" attribute. See the "Rendering the option elements" specification for ListboxRenderer for more detail on how to render the "option" elements in this renderer.

selectOneMenu

Render an HTML option list.

Decode Behavior

Encode Behavior

    Render an HTML "select" element. Render the clientId of the component as the value of the "name" attribute. If the "styleClass" attribute is specified, render its value as the value of the "class" attribute on the "select" element. If the component to be rendered is a UISelectMany, render "true" as the value of the "multiple" attribute. Use the number of items as the value of the "size" attribute. See the "Rendering the option elements" specification for ListboxRenderer for more detail on how to render the "option" elements in this renderer.

selectOneRadio

Render a set of html "input" elements of type "radio".

Decode Behavior

Encode Behavior

    Render a "table" element. If the "styleClass" is specified, render the value of the "styleClass" attribute as the value of the "class" attribute on the "table" element. If the "style", "border" attributes are specified, pass them thru. If the "layout" attribute is specified, and its value is "spread", let the radio tag do the rendering. If the "layout" attribute is specified, and its value is "pageDirection", render the children elements vertically, otherwise horizontally, in the table. If any of the children are an instance of SelectItemGroup, render them as a nested table. Render a "label" element. Each of the children are ultimately rendered as an "input" element of "type" "radio". As an exception to the general rules about how to handle the "id" attribute, render it as an attribute on the outer "table" element, the value of which is the clientId of the component per the rules at the beginning of this specification. The "id" attribute must not be output on each "input" element. Output the value of the "label" attribute of the SelectItem after the "input" element. If the value of the currently rendered child is equal to the value of the parent UISelectOne, render an appropriate HTML boolean value indicating "checked" for the enclosing "input". If the current SelectItem.isDisabled() returns true, render "disabled" as the value of the "disabled" attribute. See the "Rendering the option elements" specification for ListboxRenderer for more detail on how to render the "option" elements in this renderer. Close out the "label" element.

inputRichText

The ICEfaces inputRichText component uses the FCKEditor API to provide JSF based rich text component.
The "customConfigPath" attribute can be used to defined the custom config.js where you can customize the FCKeditor including the custom toolbar and the css.

The following steps are involved in creating the custom toolbar:

  1. Create a config file under the webapp, defining the custom toolbar(e.g.) js/config.js
    FCKConfig.ToolbarSets["MyToolbar"] = [['Bold','Italic', 'Underline'], ['Save']] ;
  2. Set the "toolbar" attribute on the inputRichText component to define the custom toolbar name and set the "customConfigPath" attribute to reference the custom config.js.(e.g.)
    <ice:inputRichText toolbar="MyToolbar" customConfigPath="js/config.js"/>

The following steps are involved in defining the custom CSS:

  1. Copy the fck_editorarea.css from the FCKeditor distribution to your app and customize it(e.g.) css/fck_editorarea.css

  2. Create a config file under the webapp, overriding the "FCKConfig.EditorAreaCSS" property(e.g.) js/config.js
    FCKConfig.EditorAreaCSS = 'http://'+ window.location.host +'/'+window.location.pathname.split("/")[1]+'/css/fck_editorarea.css' ;

  3. Set the "customConfigPath" attribute to reference the custom config.js.(e.g.)
    <ice:inputRichText customConfigPath="js/config.js"/>
loadBundle

The application of the ice:loadBundle is same as the f:loadBundle but it allows to change the messages dynamically in two ways:

  • Changing the basename using value binging allows to load new message base
  • Changing the locale causes the loadBundle component to reload messages for the specified locale

menuBar

The menuBar component provides a robust menu system that supports:

  1. Nested child menuItem and menuItemSeparator components. Support for menuItemCheckbox and menuItemRadio components are planned for a future release.
  2. Horizontal (default) and Vertical menu orientations. Defines whether the submenus of the top-level menu items appear beside or below the top-level menu items.
  3. Definition of the heirarchy of menu items and their submenus in one of two ways:
    • by using a binding to a bean method that returns a (potentially) dynamic heirarchy of menu items.
    • by statically defining the heirarchy in the JSPX page.
  4. The action attribute of the contained menuItem tags or instances can be defined to indicate a string or a backing bean method that can be used in application navigation.
  5. The actionListener attribute of the contained menuItem tags or instances can be defined to indicate an actionListener that resides in a backing bean.

See the menuItem component's description for more relevant information.

menuItem MenuItem components are the menu items contained by a menuBar. The value attribute defines the label displayed for the menuItem. The icon attribute can be used to specify an image that displays on the left side of the menuItem. The action and actionListener attributes operate in the same way os the standard component attributes of the same name. The menuItem component is only used in the static approach to defining the heirarchy of menu items.
menuItemSeparator This is the Menu Node Separator component.
menuItems This is the submenu component to use if you want to supply a (potentially) dynamic heirarchy of menuItems.
menuPopup

A context sensitive popup menu providing popup nested child menus

By default the menuPopup doesn't cause any submit when displayed by the right click, that is why its contents can be static only but it could be dynamic by just registering the displayListener on it. The displayEvent gives the target component as well as the clientId of the target component in form of contextValue, which then can be use to produce dynamic contents.

outputBody

Renders the contents of html document.

The "focus" attribute on the this component allows to focus a component by just setting the "id" or the "clientId". It also avoids the need of component binding. The value of the focus attribute can be bind to the bean using the value binding. So application can dynamically change the focus.

Note:
  • - To focus the elements inside the UIData type of components, the element can not be focused using the "id", the clientId has to be used instead.
  • - The focus would only be requested when there is a value change on the focus attribute.
  • - If you setting the initial focus, the focused component must be rendered on first render call, if not then set the focus attribute only when the component gets rendered.
outputChart

The outputChart component uses the JCharts open source charting utility (http://jcharts.sourceforge.net/) to create charts. All chart types are derived from the two main types:

  1. axis :
    • area
    • areastacked
    • bar
    • barclustered
    • barstacked
    • line
    • point
    • stock
  2. pie :
    • pie2D
    • pie3D
Note: The "type" attribute can be changed using the value binding for one basic type only. For example you can change "area" to "bar", "bar" to "line" but not to "pie2d"


outputConnectionStatus

The outputConnectionStatus component displays the information about the status of the network connection between the client browser and the server. The component displays one of 4 possible states, which are as follows.

1. Active: The connection is alive and there is a request pending.
2. Inactive: The connection is alive and there is no pending activity.
3. Caution: The connection request/response latency has exceeded the configured threshold. Indicates that asynchronous updates from the server may not be received in a timely manner.
4. Disconnected: The connection has been lost, either due to network or application error (session expiry, etc.).

The outputConnectionStatus component provides an ideal mechanism to provide continuous real-time feedback to users of the status of their ICEfaces application. It is particularly important to inform users when the application is busy sending and receiving data in response to a user-initiated action to manage their expectations with respect to application readiness for additional user input. Generally, the outputConnectionStatus component should be located in a consistent location throughout an ICEfaces application.

NOTE: A web-page may only contain a single outputConnectionStatus component. Using more than one outputConnectionStatus component on the same web page will result in erratic results.

outputDeclaration

The outputDeclaration component causes a DOCTYPE declaration to be placed at the beginning of the output document.
For example,

<ice:outputDeclaration doctypeRoot="HTML" doctypePublic="-//W3C//DTD HTML 4.01 Transitional//EN" doctypeSystem="http://www.w3.org/TR/html4/loose.dtd" />
will insert the following at the beginning of the document
<!DOCCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd" >
outputHead

head element contains meta information about html document.

outputHtml

Renders an HTML Document "html" element.

outputMedia

Renders an object tag and an embed tag for playing a media object. Parameter values specific to a player should be specified using <f:param>.

outputResource

The outputResource component can be used to expose resources to the page. These resources can be rendered as links that trigger the browser to open the resource as an attachment, or open directly from the current page. Any class that implements the com.icesoft.faces.context.Resource can be used to expose the resource.

outputStyle

The outputStyle component is used to link the desired ICEfaces theme CSS stylesheets into the page to style the ICEfaces Component Suite components.

Inserting the outputStyle component into the HEAD region of a page will link both the default CSS stylesheet for the theme and optionally an additional stylesheet that alters the default styles to accommodate differences in CSS rendering in various user-agents/browsers.

The additional style sheet will have a different extension for each browser.

  • Internet Explorer < 7 = _ie.css
  • Internet Explorer 7 = _ie7.css
  • Internet Explorer 8 = _ie8.css
  • Safari = _safari.css
  • Sun Studio Creator = _dt.css

This extension replaces the .css value of the href attribute. So when href is 'xp.css' and the page is rendered in Internet Explorer 6 or less, an additional style sheet will be included called 'xp_ie.css'.

panelCollapsible

The panelCollapsible component is comprised of two parts: the content area, where its children can be displayed; and a header section, which can be clicked on, to cause the content area to collapse into not being visible, or expand to become visible. The panelCollapsible's state of being expanded or collapsed is fully controllable via its expanded attribute, which can be tied to a bean property through a ValueBinding.

panelConfirmation

This component renders a popup confirmation dialog asking the user whether to cancel or continue with the operation that was requested. This dialog will be displayed immediately after the event that triggered the operation (e.g. click, Enter-key press, etc.) while preventing the application from carrying out the requested operation until it is confirmed by the user.

panelDivider

The panelDivider component creates a spilttable panel. The position of the divider can be defined using the "dividerPosition" attribute. The orientation of the spilttable panel can be set to the vertical or the horizontal using the "orientation" attribute.

The component requires two named facets ("first", "second") to define each pane. (e.g.)
<ice:panelDivider styleClass="myDvrPanel1">
   <f:facet name="first">
     <ice:outputText value="left"/>
   </f:facet>

   <f:facet name="second">
     <ice:outputText value="second"/>
   </f:facet>
</ice:panelDivider>

panelLayout

PanelLayout is a container used for displaying a group of components. AbsoluteLayout allow placement of components in absolute positions. A flow layout arranges components in relative alignment.

panelPopup

The panelPopup is a container component that renders a window or panel that hovers on top of a web page. The popupPanel contains 2 regions which are defined using facets. The facet names are; header and body.
The panelPopup component can be used to provide a general popup window behavior such as moveable/dragable, resizeable and modal
Note: A panelPopup facet needs a container type component as a child (e.g., panelGroup or panelGrid). panelGroup renders a span tag, which doesn't work properly if using Mozilla. panelGrid can be used to avoid display problems.

panelSeries

The panelSeries component provides a mechanism for dynamically generating a series of repeating child-components within a panel. This component renders its child components in an iterative fashion similar to way the dataTable component renders data rows. However, the panelSeries component is more flexibile in that it can render a series of arbitrarily complex child components. The dataset can be defined and used by implementing the value and var attributes respectively.

panelStack

The panelStack is a container component that itself contains multiple panel groups. A single contained panel group is visible at one time, filling the area covered by the panelStack component. The panel group specified in the selectPanel attribute will be visible, with the others being hidden.
The panelStack component can be used in cases where a form region must contain several embedded panels, only one of which is visible at one time, changing dynamically depending on an application state change or user selection.

panelTab

Renders an individual Panel Tab. Must be contained within a TabbedPane.
The label facet can be defined to the tab (e.g.)

	<ice:panelTab>
                      <f:facet name="label">
                        <ice:panelGroup>
                              <ice:outputText value="Tab 1"/>
                          </ice:panelGroup>
                      </f:facet>  
                     <ice:outputText value="Contents"/> 
    </ice:panelTab>  
    
panelTabSet

The panelTabSet is a container component which itself contains one or more panelTab components, which are also container components. The panelTabSet component displays the "active" panelTab, hiding the contents of the others. Users can select which panelTab to make visible by clicking on the tab header of the panelTab that they want to display.
The panelTabSet component can be used in cases where a file-tab navigation interface is appropriate.

panelTooltip

The panelTooltip is a container component that renders the panel as tooltip that hovers on top of an element. This component can be used with conjunction of the panelGroup.

The popupTooltip contains two user defined regions which are defined using named facets. The facet names are "header" and "body".

The hide functionality is controlled by the hideOn attribute.

Note: The panelTooltip can be draggable as well.
portlet The portlet component is a container component that renders a "div" element, outputting the value of the "style" attribute as the value of the "style" attribute and the value of the "styleClass" attribute as the value of the "class" attribute.
outputProgress

The outputProgress component can be used to report progress to users in cases where a long running server-side task is necessary. This component can be run in either of two modes; "determinate" and "indeterminate".

Determinate mode should be used in cases where the number of steps or units of work in a long-running process are known. In determinate mode (default) the outputProgress component renders a progress bar that indicates the completion percentage for a task. Typically, the progress bar will gradually progress from 0 to 100 % complete in incremental steps determined by the application.

Indeterminate mode should be used in cases when it is not possible to predicate how long a long-running process will take to complete, or how many steps or units of work are required to complete the task. In indeterminate mode the outputProgress component renders an animated icon or progress bar that indicates generally that activity is taking place.

rowSelector The Row Selector tag enables single and multiple row selection for DataTable. To add the row selection to the dataTable, the rowSelector component can be added to any column of the dataTable(e.g.)

<ice:dataTable..>
  <ice:column>
    <ice:rowSelector .../>
    <f:facet name="header">
      <ice:outputText ..../>
    </f:facet>
    <ice:outputText ...../>
  </ice:column>

Note:
  • there should be only one rowSelector component inside a dataTable.

    The row selection will fire a RowSelectorEvent which can be caught by the selectionListener on this component.

    The selection is based on the following two attributes:

    • multiple
    • enhancedMultiple
    By default the component runs in single selection mode. In which selecting a row deselects the previously selected row. Setting "multiple" to true, puts the component in multiple selection mode, which allows you to select multiple rows but you can not use "ctrl" or "shift" keys for selection.
    Setting the "enhancedMultiple" to true, allows single or muliple selection using the shift or ctrl keys combination. For more detail please see the attribute specific description.

  • It is a good practice to use the immediate parameter of the rowSelector. If set to true, it will work with the results of the selection in APPLY_REQUEST_VALUE phase, before validation occurs. If set to false it will defer event processing until INVOKE_APPLICATION phase, after validation. If validation fails, selection event will not fire with immediate=false
  • The event lists selection changes tied to the event, not the total model state. So the RowSelectorEvent.getSelectedRows() can return multiple rows only when the selection was made using the "shift" key in enhancedMultiple mode, other wise it returns a single rowindex. To determine all the currently selected rows in a dataTable the application needs to query the model
selectInputDate

The selectInputDate component renders a localized dateSelect. Users may select a date by clicking on a date in the displayed month. The displayed month and year can be changed using arrow buttons or dropdown lists. Optionally, the selectInputDate component may be used in popup mode. In this mode an inputText component is rendered that displays the selected date. Users may enter a date directly into the inputText component, or optionally click a button beside the inputText component to display a popup dateSelect view. Selecting a date in the dateSelect closes the popup dateSelect view and updates the selected date.
The selectInputDate component can be used in cases where a date value must be displayed or entered.

In order to highlight a day, following three attributes need to be set with corresponding values:

  1. highlightClass
  2. highlightUnit
  3. highlightValue
(e.g.) <ice:selectInputDate highlighClass="newyear" highlightUnit="DAY_OF_YEAR" highlightValue="1" />

To highlighting days in more granular fashion, above attributes can be set to defining more then one rules by separating them with : colon (e.g.)
<ice:selectInputDate highlighClass="newyear: weekend" highlightUnit="DAY_OF_YEAR: DAY_OF_WEEK" highlightValue="1: 7" />

A rule can be set to defining more then one values using comma "," (e.g.)
<ice:selectInputDate highlighClass="newyear: weekend" highlightUnit="DAY_OF_YEAR: DAY_OF_WEEK" highlightValue="1: 1, 7" />

NOTE: all 3 highlight attributes should have a corresponding values.
The action and actionListener will only be fired, when "enter" being pressed on a input text in a popup mode.

Time Entry: When the f:convertDateTime is configured to show time, the calendar will include a time editing UI.
selectInputText

The selectInputText component provides an inputText component enhanced with auto-complete functionality. As the user enters text into the component it provides a popup list of possible matching values that the user may select from. The component predicts a word or phrase that a user wants to type in without the user actually completely typing it in. The selectInputText component requires developers to implement the matching list search algorithm in their backing bean.

The selectInputText component can generate one of two types of lists:
1. A list of String data.
2. A list of arbitrarily complex child components.

The server call delay frequency can be configured using the "options" attribute. Please see the description of "options" attribute for detail.

setEventPhase The Set Event Phase component allows one to specify the phase that certain events will be broadcast in, for events originating from components in its child hierarchy. The component has the following attributes
  • events Space delimited list of class names of events that should be changed to be broadcasted in the specified phase. Default is for no events to be affected.
  • phase The phase for the spefified events to be broadcasted in. One of: ANY, APPLY_REQUEST_VALUES, PROCESS_VALIDATIONS, UPDATE_MODEL_VALUES, INVOKE_APPLICATION.
commandSortHeader

The commandSortHeader component is used in conjunction with a dataTable. The commandSortHeader renders a clickable column header facet allowing the user to toggle the sort order of data in the table, either ascending or descending based on the values in the column.
The commandSortHeader can be used to provide a user-controlled data sorting capability to a dataTable.

treeNode

The treeNode tag provides the template that be applied in rendering each node in the backing data model. The treeNode tag supports two facets: the icon facet and the content facet. The icon facet is intended to contain a graphic image that will serve as the icon for the node it represents. This image can be customized for each node, or default icons for leaf nodes, expand branch nodes, and contracted branch nodes will be used. The content facet can contain any collection of components. For each node in the tree's backing data model, the child components of the two facets will be rendered with state retrieved from the data model as configured in the JSP by the application developer.

tree

The tree component displays hierarchical data as a "tree" of branches and leaf nodes. Optionally, the tree may also display navigation controls for the dynamic expansion and collapse of branch nodes. Tree navigation events are available so that an application can respond to these events. Nodes may also support an action event that can be used to respond to user click events.
The tree component can be used in cases where a hierarchical data structure must be viewed and navigated. It is typically used for menu-style applications, where the user selects a tree node and the application responds with an action related to the selected node.
In implementing a tree tag, the application developer must provide declare in the JSP a tree tag and a single treeNode tag as a child of the tree tag. The tree tag should declare the "value" attribute to be a value binding to a backing bean that will return an object that implements the javax.swing.tree.TreeModel interface. The TreeModel must contain a tree of DefaultMutableTreeNode instances. Each DefaultMutableTreeNode instance encapsultes an IceUserObject. The IceUserObject is the extension point for the application developer. If the IceUserObject does not provide sufficient state for representation of the tree's nodes, then the application developer should extend the IceUserObject and add state as required to their extension. When creating an IceUserObject, the DefaultMutableTreeNode wrapper must be provided to the constructor. Then the node's state can be set to the attributes on the IceUserObject including: text, a convenience field that will typically represent the text that will be displayed somewhere in the content facet; expanded, whether the node is expanded on its first rendering and until the user initiates a navigation event to change this value; tooltip, the text that will appear in the tooltip that appears when the user hovers over a node; leafIcon, the application-relative path to an image that will be used to represent this node when it has no children (is a leaf), typically referred to in the icon facet; branchExpandedIcon, the application-relative path to an image that will be used to represent this node when it has children (is a branch) and is expanded, typically referred to in the icon facet; branchContractedIcon, the application-relative path to an image that will be used to represent this node when it has children (is a branch) and is not expanded, typically referred to in the icon facet. The "binding" attribute can be defined so that the application developer will have access to the Tree component in the application's backing bean. The "var" attribute can be declared on the tree tag such that the treeNode tag's children have access to the state of the TreeModel's node that it represents.
See the documentation for the treeNode tag for a description of supported facets.

panelPositioned With the positioned panel component lists can be used to generate a series of repeating child-components within a panel. Each one of these child-components is draggable and can exchange positions with other children in the same panel as well as a child component can be moved between different positioned panels components. When a Child Component is moved the source value (java.util.List/Array ) for the positioned Panel is modified by the component to reflect the new order of the positioned panel.
(e.g.)
<ice:panelPositioned var="person"
value="#{panelPositioned.people}" >
<ice:panelGroup style="cursor:move;">
<ice:outputText value="#{person.name}"/>
</ice:panelGroup>
</ice:panelPositioned>
tabChangeListenerNo Description
 


Java, JSP, and JavaServer Pages are trademarks or registered trademarks of Sun Microsystems, Inc. in the US and other countries. Copyright 2002-3 Sun Microsystems, Inc. 4150 Network Circle Santa Clara, CA 95054, U.S.A. All Rights Reserved.