but its still confusing as hell to have a constructor like

DropDownChoice(String, IModel, IModel)

it just plain sucks

generics will make it much better

DropDownChoice<T>(String, IModel<T>, IModel<List<T>>)

then at a glance you know where things go.


and yes IModel is a tricky beast, mainly because it is so flexible. though, i think once you get used to it you can wield its power quiet effortlessly.

-Igor


On 5/5/06, Johan Compagner <[EMAIL PROTECTED]> wrote:


One thing I found particularly awkward was how models work in some of
the form widgets, i.e. DropDownChoice, ListMultipleChoice, etc.  This
is where I found the Wicket learning curve was greater because it
wasn't nearly as intuitive as I had expected.

Strange thing is they work exactly like Swing Comboboxes and Lists..
The selected objects are just the objects that are in the total list.

And you have a Renderer that displays the objects.. (to display a text in a label that is the "toString" of the object)

The only difference is is that in wicket you also need to generate a String id because we need that to send to the browser.

johan


Reply via email to