Hi Mark, I implemented this feature for MyFaces and I ran into the same bug on Mojarra. After some blackbox tests I figured out that they are not using a converter when setting the value in the managed bean, thus the values are of type String.
On my point of view, MyFaces is doing right! Regards, Jakob 2010/1/9 Mark Struberg <[email protected]> > Hi! > > I'm currently using Mojarra-2.0.1 and MyFaces-2.0.0-SNAPSHOT in parallel, > testing out a few things. > > One of the compatibility problems I got was with using > > in my backing bean: > > public SelectItem[] getRooms() { > .. > item[i] = new SelectItem( roomIntegerId, roomName ); > .. > } > > for MyFaces, I need to use > public void setSelectedRooms(List<Integer> selectedRooms) { > .. > } > > whereas for Mojarra, I need to use > public void setSelectedRooms(List<String> selectedRooms) { > .. > } > > otherwise I get a ClassCastException. > > Which implementation is doing it correct and which one is wrong? > > From looking at Suns SelectItem 2.0 JavaDoc, > > > Object getValue() > > Return the value of this item, to be delivered to the model if this item > > is selected by the user. > > I'd say MyFaces is doing it right (SelectItem would not have an Object but > a String parameter otherwise ...) > But I'm not sure since mojarra is still the RI. > > txs and LieGrue, > strub > > > >

