« Return to Thread: users, please give us your opinion: what is your take on generics with Wicket

Re: users, please give us your opinion: what is your take on generics with Wicket

by Tsutomu Yano :: Rate this Message:

Reply to Author | View in Thread


On 2008/06/02, at 5:44, Eelco Hillenius wrote:

> 1) Generifying* Wicket

  [X] Can best be done like currently in the 1.4 branch, where models
and components are both generified. I care most about the improved
static type checking generified models and components give Wicket.

  For me, the most important thing is that component's getModelObject() method
returns a object with correct type, which the IModel have, without casting.
If it will be not realized, generifying Wicket have no mean.

  it is needed generifying both of components and models to realize that.
If components will be not generified, getModelObject() method will return Object type always,
then I need casting it.
  I often usegetModelObject() method.


>  2) How strongly do you feel about your choice above?


  [X] I might rethink upgrading if my choice doesn't win.


  However, I can understand that the way like Page<Void>, Link<Void> is
verbose. So we can avoid the verbosity creating some generic classes for components.
Like:

  - Page<T>
  - GenericPage extends BasePage<Void>

  If I want not write Page<Void>, you can simply use GenericPage class instead.

----------------------
Tsutomu YANO
benbrand at mac.com
Tokyo, Japan

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@...
For additional commands, e-mail: users-help@...

 « Return to Thread: users, please give us your opinion: what is your take on generics with Wicket