Ahh... But there in lines the real point.

What happens 2 years down the road when you need to modify that component?
A) if its not typed then you hunt around and try and find out what it was...
Maybe you do a println of the fqn...
B) its typed... Your done. 

Even the time it takes to "discover" the model has direct bearing on ROI
(although a lot of developers tend not to think on it much, we all depend on
it) and the stats (and experience) say 80% of your work is maintenance.

So, forget the 20%, lets chew away some of that 80%.

- Brill Pappin

-----Original Message-----
From: John Krasnay [mailto:[EMAIL PROTECTED] 
Sent: Monday, June 02, 2008 3:28 PM
To: users@wicket.apache.org
Subject: Re: users, please give us your opinion: what is your take on
generics with Wicket

On Mon, Jun 02, 2008 at 03:05:46PM -0400, Hoover, William  wrote:
> I got the point, but I take things as people state them. It was stated 
> that 70% of the time models are not being used (such is the case for 
> Link<Void>). As you stated, they are being used indirectly. That is 
> different. If that is the case then I agree that the percentage of 
> components using model indirectly would be reduced for "form-heavy"
> applications (as you stated). On the contrary, a lot of applications 
> are not "form-heavy" (i.e. Ajax heavy apps, etc.) which also need to 
> be accounted for in the figures.
> 

I would contend that the important thing to look at is not the percentage of
component instances that use models, but the percent for which your code
explicitly calls getModel() or getModelObject(). If you're not calling one
of these methods, you have received no value for typing the generic syntax.
I would be surprised if I explicitly call one of these methods on more than
about 20% of my Wicket component instances. 

So for me, it's not the verbosity of generics that is the problem. When the
syntax is helping you avoid a cast somewhere else, it's worth it.
What bothers me is that 80% of time (for me, anyway) it doesn't save me a
cast, it just makes for more typing and less readable code.

(Also, please keep in mind I'm referring to genericizing Component. Like
most on this thread I'm a big fan of genericizing IModel.)

jk

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to