Tobago Components


Standard Syntax:
     <%@ taglib prefix="tc" uri="http://myfaces.apache.org/tobago/component" %>

XML Syntax:
     <anyxmlelement xmlns:tc="http://myfaces.apache.org/tobago/component" />

Tobago Framework Component Tag Library - (C) Copyright 2005-2010 The Apache Software Foundation

Tag Library Information
Display NameTobago Components
Version1.0
Short Nametc
URIhttp://myfaces.apache.org/tobago/component
 

Tag Summary
attributeAdd an attribute on the UIComponent associated with the closest parent UIComponent custom action.
converterRegister an Converter instance on the UIComponent associated with the closest parent UIComponent.
validateFileItemRegister an FileItemValidator instance on the UIComponent associated with the closest parent UIComponent custom action.
forEach

**** @deprecated. Will be removed in a future version ****

Replacement for the JSTL <c:foreach> tag.
This tags iterates over the body content without setting up an exported scope variable, but replaces all occurrence's of var in TobagoTag's ValueBinding attributes.
All non TobagoTags are treated as they are, no replacement is done, and so no ability to use the var in el.
include

**** @deprecated. Will be removed in a future version ****

loadBundleLoad a resource bundle localized for the Locale of the current view from the tobago resource path, and expose it (as a Map) in the request attributes of the current request.
popupReferenceRegister an PopupActionListener instance on the UIComponent associated with the closest parent UIComponent.
scriptThis tag add client side script to the rendered page.
styleAdd a style tag. Collected bodyContent is rendered as content into a style tag.
validateSubmittedValueLengthRegister an SubmittedValueLengthValidator instance on the UIComponent associated with the closest parent UIComponent custom action. The standard LengthValidator validate the length on the converted value.toString() not on the submitted value. Sometime you need to check the length of the submitted value.
tabChangeListenerRegister an TabChangedListener instance on the UIComponent associated with the closest parent UIComponent custom action.
boxRenders a panel with border and title.

UIComponentClass: org.apache.myfaces.tobago.component.UIBox

RendererType: Box

Supported facets:

toolBar
Contains an instance of UIToolBar
layout
Contains an instance of UILayout
buttonRenders a button element.

UIComponentClass: org.apache.myfaces.tobago.component.UIButtonCommand

RendererType: Button

Supported facets:

confirmation
Contains a UIOutput instance with the confirmation message.
popup
Contains a UIPopup instance.
calendarRenders a calendar.

UIComponentClass: javax.faces.component.UIOutput

RendererType: Calendar

cellRenders a layout cell. A panel with ability to span over more than one layout cells.

UIComponentClass: org.apache.myfaces.tobago.component.UICell

RendererType: Panel

columnEventThis component creates an event in a UISheet for each row.

UIComponentClass: org.apache.myfaces.tobago.component.UIColumnEvent

RendererType:

columnSelectorRenders a column with checkboxes to mark selected rows.

UIComponentClass: org.apache.myfaces.tobago.component.UIColumnSelector

RendererType: ColumnSelector

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

UIComponentClass: org.apache.myfaces.tobago.component.UIColumn

RendererType:

commandUse this tag only as a facet for click, change in selectOneRadio, selectBooleanCheckbox, selectManyCheckbox and selectOneChoice

UIComponentClass: org.apache.myfaces.tobago.component.UICommand

RendererType: Command

datePickerRenders a date picker. The component needs a DateFormat Pattern from a converter. The converter should be an instance of DateTimeConverter and return a valid pattern from the method getPattern()

UIComponentClass: org.apache.myfaces.tobago.component.UIDatePicker

RendererType: DatePicker

dateRenders a date input field.

UIComponentClass: org.apache.myfaces.tobago.component.UIDateInput

RendererType: Date

fileRenders a file input field. You need to define an org.apache.myfaces.tobago.webapp.TobagoMultipartFormdataFilter in your web.xml or add the tobago-fileupload.jar to your project. The tobago-fileupload.jar contains a FacesContextFactory that wraps the multipart-formdata request inside the facesContext.

For content constraints please use tc:validateFileItem.

UIComponentClass: org.apache.myfaces.tobago.component.UIFileInput

RendererType: File

form

UIComponentClass: org.apache.myfaces.tobago.component.UIForm

RendererType: Form

gridLayoutRenders a GridLayout.
 columns/rows ::= LAYOUT LAYOUT ::= TOKEN [";" TOKEN]+ TOKEN ::= FIXED | PIXEL | PROPORTIONAL FIXED ::= "fixed" PIXEL ::= NUMBER "px" PROPORTIONAL ::= [NUMBER] "*" 

Parent Child Okay? Remarks
FIXED any combination of FIXED or PIXEL but no PROPORTIONAL okay -
FIXED any combination with at least one PROPORTIONAL wrong LayoutManager cannot compute the fixed value.
PIXEL any combination of FIXED or PIXEL but no PROPORTIONAL potentially wrong The values depend on each other, the programmer has to keep consistency manually.
PIXEL any combination with at least one PROPORTIONAL okay -
PROPORTIONAL any combination of FIXED or PIXEL but no PROPORTIONAL potentially wrong No automatical matching:
  • too little space: scrollbar
  • too much space: elements will be spreaded.
PROPORTIONAL any combination with at least one PROPORTIONAL okay -

UIComponentClass: org.apache.myfaces.tobago.component.UIGridLayout

RendererType: GridLayout

hiddenRenders a 'hidden' input element.

UIComponentClass: org.apache.myfaces.tobago.component.UIHiddenInput

RendererType: Hidden

imageRenders a Image.

UIComponentClass: javax.faces.component.UIGraphic

RendererType: Image

inRenders a text input field.

UIComponentClass: org.apache.myfaces.tobago.component.UIInput

RendererType: In

labelRenders a label component.

UIComponentClass: org.apache.myfaces.tobago.component.UILabel

RendererType: Label

linkRenders a link element.

UIComponentClass: org.apache.myfaces.tobago.component.UILinkCommand

RendererType: Link

Supported facets:

confirmation
Contains a UIOutput instance with the confirmation message.
popup
Contains a UIPopup instance.
menuBarRenders a menu bar.
Add menu bar as facet name="menuBar" to page tag or use it anywhere on page.

UIComponentClass: javax.faces.component.UIPanel

RendererType: MenuBar

menuCheckbox

**** @deprecated. Will be removed in a future version ****

Renders a checkable menuitem.

UIComponentClass: org.apache.myfaces.tobago.component.UISelectBooleanCommand

RendererType: MenuCommand

menuItemRenders a menu item.

UIComponentClass: org.apache.myfaces.tobago.component.UIMenuCommand

RendererType: MenuCommand

menuRadio

**** @deprecated. Will be removed in a future version ****

Renders a submenu with select one items (like a radio button).

UIComponentClass: org.apache.myfaces.tobago.component.UISelectOneCommand

RendererType: MenuCommand

menucheck

**** @deprecated. Will be removed in a future version ****

Renders a checkable menuitem.

UIComponentClass: org.apache.myfaces.tobago.component.UISelectBooleanCommand

RendererType: MenuCommand

menuradio

**** @deprecated. Will be removed in a future version ****

Renders a submenu with select one items.

UIComponentClass: org.apache.myfaces.tobago.component.UISelectOneCommand

RendererType: MenuCommand

menuSeparatorRenders a separator.

UIComponentClass: org.apache.myfaces.tobago.component.UIMenuSeparator

RendererType:

menuContainer component to hold submenus and items.

UIComponentClass: org.apache.myfaces.tobago.component.UIMenu

RendererType:

message

**** @deprecated. Will be removed in a future version ****

Renders error/validation message.

UIComponentClass: javax.faces.component.UIMessage

RendererType: Message

messagesRenders error/validation messages.

UIComponentClass: org.apache.myfaces.tobago.component.UIMessages

RendererType: Messages

object

UIComponentClass: javax.faces.component.UIOutput

RendererType: Object

outRenders a text

UIComponentClass: org.apache.myfaces.tobago.component.UIOutput

RendererType: Out

pageRenders a page element.

UIComponentClass: org.apache.myfaces.tobago.component.UIPage

RendererType: Page

Supported facets:

action
Contains an instance of UICommand (tc:command) for an auto-action
resizeAction
Contains an instance of UICommand (tc:command) or a UIForm (tc:form) with a UICommand for a resize-action
menuBar
Menubar
layout
Contains an instance of UILayout
panelIntended for use in situations when only one UIComponent child can be nested, such as in the case of facets.

UIComponentClass: org.apache.myfaces.tobago.component.UIPanel

RendererType: Panel

Supported facets:

reload
Contains an instance of UIReload
layout
Contains an instance of UILayout
popupRenders a popup panel.

UIComponentClass: org.apache.myfaces.tobago.component.UIPopup

RendererType: Popup

progressRenders a progressbar.

UIComponentClass: org.apache.myfaces.tobago.component.UIProgress

RendererType: Progress

Supported facets:

complete
Contains an instance of UICommand (tc:command). The action is invoked if the full progress has reached
reloadUpdate the parent component

UIComponentClass: org.apache.myfaces.tobago.component.UIReload

RendererType:

selectBooleanCheckboxRenders a checkbox.

UIComponentClass: org.apache.myfaces.tobago.component.UISelectBoolean

RendererType: SelectBooleanCheckbox

Supported facets:

click
This facet can contain a UICommand that is invoked in case of a click event from the component
change
This facet can contain a UICommand that is invoked in case of a change event from the component
selectItemAdd a child UISelectItem component to the UIComponent associated with the closed parent UIComponent custom action.

UIComponentClass: org.apache.myfaces.tobago.component.UISelectItem

RendererType:

selectItemsAdd a child UISelectItems component to the UIComponent associated with the closed parent UIComponent custom action.

UIComponentClass: javax.faces.component.UISelectItems

RendererType:

selectManyCheckboxRender a group of checkboxes.

UIComponentClass: org.apache.myfaces.tobago.component.UISelectMany

RendererType: SelectManyCheckbox

selectManyListboxRender a multi selection option listbox.

UIComponentClass: org.apache.myfaces.tobago.component.UISelectMany

RendererType: SelectManyListbox

selectOneChoiceRender a single selection dropdown list.

UIComponentClass: org.apache.myfaces.tobago.component.UISelectOne

RendererType: SelectOneChoice

Supported facets:

click
This facet can contain a UICommand that is invoked in case of a click event from the component
change
This facet can contain a UICommand that is invoked in case of a change event from the component
selectOneListboxRender a single selection option listbox.

UIComponentClass: org.apache.myfaces.tobago.component.UISelectOne

RendererType: SelectOneListbox

Supported facets:

click
This facet can contain a UICommand that is invoked in case of a click event from the component
change
This facet can contain a UICommand that is invoked in case of a change event from the component
selectOneRadioRender a set of radiobuttons.

UIComponentClass: org.apache.myfaces.tobago.component.UISelectOne

RendererType: SelectOneRadio

Supported facets:

click
This facet can contain a UICommand that is invoked in case of a click event from the component
change
This facet can contain a UICommand that is invoked in case of a change event from the component
selectReferenceRenders a set of option related to and same type as the for component.

UIComponentClass: javax.faces.component.UIOutput

RendererType: SelectReference

separatorRenders a separator.

UIComponentClass: org.apache.myfaces.tobago.component.UISeparator

RendererType: Separator

Supported facets:

label
This facet contains a UILabel
sheetRender a sheet element.

UIComponentClass: org.apache.myfaces.tobago.component.UIData

RendererType: Sheet

Supported facets:

reload
Contains an instance of UIReload
tabGroupRenders a tab panel.

UIComponentClass: org.apache.myfaces.tobago.component.UITabGroup

RendererType: TabGroup

tabRenders a tab within a tabgroup.

UIComponentClass: org.apache.myfaces.tobago.component.UITab

RendererType: Tab

textareaRenders a multiline text input control.

UIComponentClass: org.apache.myfaces.tobago.component.UIInput

RendererType: TextArea

timeRenders a time input field.

UIComponentClass: org.apache.myfaces.tobago.component.UITimeInput

RendererType: Time

toolBarCommandRenders a command button within a toolbar.

UIComponentClass: org.apache.myfaces.tobago.component.UICommand

RendererType: Button

toolBarCheckRenders a selectable command button within a toolbar.

UIComponentClass: org.apache.myfaces.tobago.component.UISelectBooleanCommand

RendererType: MenuCommand

toolBarSelectOneRenders a set of radio command button's within a toolbar.

UIComponentClass: org.apache.myfaces.tobago.component.UISelectOneCommand

RendererType: MenuCommand

toolBar

Renders a toolbar.

Allowed subcomponents are subtypes of UICommand i.e. 'button' and 'link' tags. These are rendered by ToolbarRenderer, so the result has no difference.

To add an dropdown menu to a button add a facet 'menupopup' containing a <tc:menu> tag to the button. Label's and Image's on those menu tag's are ignored and replaced by the renderer.

 <tc:button onclick="alert('test 0')" label="Alert 0" > <f:facet name="menupopup"> <tc:menu> <tc:menuItem onclick="alert('test 1')" label="Alert 1"/> <tc:menuItem onclick="alert('test 2')" label="Alert 2"/> <tc:menuItem onclick="alert('test 3')" label="Alert 3"/> </tc:menu> </f:facet> </tc:button> 

UIComponentClass: org.apache.myfaces.tobago.component.UIToolBar

RendererType: ToolBar

treeListbox

**** Preliminary. Maybe subject to changed in a future version: Implement a var attribute for the tree like in the sheet (http://issues.apache.org/jira/browse/TOBAGO-18) ****

Renders a listbox view of a tree.

UIComponentClass: org.apache.myfaces.tobago.component.UITreeListbox

RendererType: TreeListbox

tree

**** @deprecated. Will be removed in a future version ****

Renders a tree view.

UIComponentClass: org.apache.myfaces.tobago.component.UITreeOld

RendererType: TreeOld

 

Listeners
org.apache.myfaces.tobago.webapp.TobagoServletContextListener
org.apache.myfaces.tobago.webapp.SecretSessionListener
 


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.