Binding a Collections field with FieldGroup in a form

I have this code for a Bean


public class LocationBean{
          private List<String> ids;

           // getters & setter
          //...
 }

Then in the FORM I want to bind the field
“ids”
so I can get a collection of of Strings when I call the
commit()
method on the
FieldGroup
object


public class LocationForm extends FormLayout {  
  public LocationForm() {

  final BeanItem<LocationBean> item= new BeanItem<LocationBean>(new LocationBean());

   final FieldGroup binder= new FieldGroup(item);

   ListSelect list = new ListSelect(" List of IDS");
   list.addItem(" 1");
   list.addItem(" 2");
   list.setNullSelectionAllowed(false);
   list.setMultiSelect(true);

   binder.bind(list, "ids");  // <-----[color=#f90505]
[b]
This DOES NOT WORK!!!
[/b]
[/color]       

}      

How can I make the last line in the above code work, if this is possible in Vaadin 7? It works with simple properties like ints , Dates and Strings, but not Collections or Class Objects.

Does making your List a Set work?

-Dan

Dan, it doesn’t work either. I am thinking of just doing it manually by registering the
ListSelect
with
ValueChangeListener
and then just get values using
ids = (Collection) property.getValue();

Boni