Component that only renders a subset of its children components. Provides functionality that the JSTL choose tag has, but leverages the {@link javax.faces.component.UIComponent#isRendered()} method instead of using when tags with test attributes.
It can either use a filter type of "count" or "index". If count, the given number of children will be rendered (so for example, a value of 2 will cause the first two children that are have a true isRendered result to be rendered. If index, it will render the given indexes.
Attributes |
Name | Required | Request-time | Type | Description |
type | false | false | java.lang.String | The filter type: count|index. count: the value should evaluate to a Number or a value that can be parsed into an integer. index: A collection, array or comma-separated list of numbers. (Default: "count") |
value | false | false | java.lang.String | The value valid for the type. If this evaluates to null, all children will be rendered. If the type is count, this value must evaluate to a java Number instance or a value which the toString() method can be used with Integer.parseInt(String). The first number of children that are rendered (isRendered() returns true) up to the given value will be rendered. If the type is index, the value must be a Collection, int[], Object[] or a comma-separated list of numbers. Each item in the list must be a valid number. If negative, it is taken from then end. If the child at the given index is not rendered, then that component is skipped (so the indexes are absolute). See the documentation on the myfaces website for more information. |
id | false | false | java.lang.String | An identifier for this particular component instance within a component view. The id must be unique within the scope of the tag's enclosing NamingContainer (eg h:form or f:subview). The id is not necessarily unique across all components in the current view This value must be a static value, ie not change over the lifetime of a component. It cannot be defined via an EL expression; only a string is permitted. |
rendered | false | false | java.lang.String | A boolean value that indicates whether this component should be rendered. Default value: true. |
binding | false | false | java.lang.String | Identifies a backing bean property (of type UIComponent or appropriate subclass) to bind to this component instance. This value must be an EL expression. |