The <ui:repeat>
tag is a component handler that is capable of iterating over a collection, and at each iteration, it adds a copy of its child elements in the component tree. We can say that <ui:repeat>
acts as a <h:dataTable>
tag without rendering an HTML table. Of course, you can do that explicitly, by wrapping its mechanism in a <table>
, <tr>
, and <td>
suite (you will see an example in the upcoming section, Using the jsfc attribute).
It contains a set of very handy attributes that deserve to be mentioned before an example. Besides the well known attributes, value
(representing the collection to iterate as java.lang.Object
) and var
(representing the iterator as java.lang.Object
), we have––all the following attributes that are optional: