Hi,

ListChoice component uses a strange way to set/get the default max
rows via "protected static" methods.
What is the design choice here ?

This default value is used if the user didn't provide the value
explicitly as a constructor parameter.
By using 'protected' method to set a new value the user is obliged to
extend this class, but then why not pass his value to the super
constructor directly ?
By being 'protected' the user's impl can reach this method also if it
is in the same package 'o.a.w.***'. But I doubt anyone would go this
way either.
And the default value is 'static' which is yet another strange design
decision which other Wicket form components do not provide.

The code is there since 2005 so I guess it is a legacy which should be removed.

-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com

Reply via email to