Matej Knopp-2 wrote:
> 
> Or maybe I took it too far and GenericLink and GenericButton would suffice
> :)
> 

Yeah, having components generic by default but making non-generic subclasses
for components that are *normally* used that way avoids the an explosion of
subclasses.

For example, I have created:

public class Container extends WebMarkupContainer
{
        public Container(String id)
        {
                super(id);
                setOutputMarkupPlaceholderTag(true);
        }
}

but obviously the generic base class WebMarkupContainer<T> should be used as
the extension point in the hierarchy so there is no explosion.

The reason I put LinkGeneric rather than GenericLink was simply so that the
two options would appear next to each other in code completions.  But of
course in English GenericLink is more correct.  If we all spoke Spanish I
guess class names would work better with code completions ;)

John



-- 
View this message in context: 
http://www.nabble.com/%28Class%3C--extends-Page%3C-%3E%3E%29--casting-troubles-tp17355847p17446565.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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

Reply via email to