nxl


Standard Syntax:
     <%@ taglib prefix="nxl" uri="http://nuxeo.org/nxforms/layout" %>

XML Syntax:
     <anyxmlelement xmlns:nxl="http://nuxeo.org/nxforms/layout" />

Tags for layout system usage.

Defines helpers tags to display layouts and widgets.

Note that some attributes are used to determine what components will be part of the jsf component tree, so they have to be resolved early: they cannot use variables like iteration variables, coming for instance from a ui:repeat or a h:dataTable tag. This is true for layout names, modes and widget instances.

Library functions:

Tag Library Information
Display NameNone
Version1.0
Short Namenxl
URIhttp://nuxeo.org/nxforms/layout
 

Tag Summary
widgetType

Facelet tag handler that renders a widget outside of a layout context, in a given mode.

This is helpful to reuse an existing widget within templates that do not need an entire layout to be defined.

In addition to the following attributes, any optional attributes are accepted and are used as properties of the created widget.

When rendered, some variables are exposed to the resolution context:

  • 'value' references the given widget value, so that it can be used in a generic template for widgets of type 'template', for instance.
  • 'widget' references the created widget.
  • widgets of type 'template' also expose field values by 'field_0' or 'field_1',... the number being the field definition index in the field definitions list.

widget

Facelet tag handler that renders a widget in a given mode.

When rendered, some variables are exposed to the resolution context:

  • 'value' references the given widget value.
  • 'widget' references the widget. It is also referenced by 'widget_0' or 'widget_1',... the number being the widget level in the hierarchy of widgets.
  • widgets of type 'template' also expose field values by 'field_0' or 'field_1',... the number being the field definition index in the field definitions list.

Any additional property set on the tag and that is not explicitely in the list of handled attributes is added to the widget properties, overriding properties that already set in the widget definition.

layout

Facelet tag handler that renders a layout in a given mode.

When rendered, some variables are exposed to the resolution context and can be used within the template attached to the layout.

  • 'layout' references the computed layout.
  • 'value' or 'layoutValue' references the given value, so that it can be used in the widget properties definitions, for instance. The 'value' variable is updated to the value passed to widget tag in a widget rendering context.

Any additional property set on the tag and that is not explicitely in the list of handled attributes is added to the layout properties, overriding properties that already set in the layout definition.

layoutRow

Facelet tag handler that iterates over layout rows in a layout template.

When rendered, some variables are exposed to the resolution context and can be used inside the tag:

  • 'layoutRow' and since 5.3.1, alias 'layoutColumn' reference the current layout row or column.
  • 'layoutRowIndex' and since 5.3.1, alias 'layoutColumnIndex' reference its index in the layout list of rows/columns.

layoutColumnFacelet tag handler equivalent to layoutRow tag, available since 5.3.1.
layoutRowWidget

Facelet tag handler that iterates over widgets in a layoutRow tag, in a layout template.

When rendered, some variables are exposed to the resolution context and can be used inside the tag:

  • 'widget' or 'widget_0' references the current widget, 0 being its level in the widgets hierarchy.
  • 'widgetIndex' references its index in the layout row list of widgets.

layoutColumnWidgetFacelet tag handler equivalent to layoutRowWidget tag, available since 5.3.1.
subWidget

Facelet tag handler that iterates over sub widgets in a template attached to the widget of type 'template'.

When rendered, some variables are exposed to the resolution context and can be used inside the tag:

  • 'widget' or 'widget_n' references the current widget, n being its level in the widgets hierarchy. For instance, the root of all widgets is always referenced as 'widget_0', while 'widget' is updated to the current sub widget value.
  • 'widgetIndex' or 'widgetIndex_n' references its index in the layout row list of widgets or in the widget list of sub widgets. It is *not* the sub widget iteration number when iterating over a list of objects.

documentLayout

Facelet tag handler that renders all layouts attached to a document in a given mode.

Layouts are built using the document type definition. This tag is equivalent to rendering each layout in given mode, using document as value.

Any additional property set on the tag and that is not explicitely in the list of handled attributes is added to each of the layouts properties, overriding properties that already set in the layout definitions.

 


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.