it is a "callback" that is used by the listview itself. It calls it for every object in the model list. Its there so you can "inject" your own functionality into the listview, in this case it is used so that you can populate each item with your own hierarchy of components.

-Igor


On 11/2/05, Paulo Sérgio Medeiros <[EMAIL PROTECTED]> wrote:
Hi all, im new to Wicket, and a bit in java (have experience in other oo languages).

I dont understand the populateItem construction. Who calls it? When?

add(new ListView("rows", listData)

{
public void populateItem(final ListItem item)
{
final UserDetails user = (UserDetails)item.getModelObject();
item.add(new Label("id", user.getId()));
}
});

Thanks in advance,

Paulo Sergio.


Reply via email to