That is my situation. I would like to inject stuff at different places in the 
subpanel.  Hopefully the <wicket:child/> and <wicket:extend> will be 
sufficient. I will review the examples.

Thanks

-----Original Message-----
From: [email protected] [mailto:[email protected]] On 
Behalf Of James Carman
Sent: Thursday, February 24, 2011 12:26 PM
To: [email protected]
Subject: Re: Panel Inheritance

However, sometimes that just doesn't work, because you want to inject
stuff at different places in the subpanel.  You can override the
entire markup file if you want in that case, right?

On Thu, Feb 24, 2011 at 12:24 PM, Martin Grigorov <[email protected]> wrote:
> The Wicket way is to use <wicket:child/> in MyPanel.html and
> <wicket:extend>....</wicket:extend> in MyExtPanel.html
> See the examples.
>
> On Thu, Feb 24, 2011 at 7:05 PM, GOODWIN, MATTHEW (ATTCORP)
> <[email protected]>wrote:
>
>> I would like to extend a custom panel that we have and add some
>> additional components.
>>
>>
>>
>> Ex pseudocode:
>>
>>
>>
>> public class MyPanel extends Panel {
>>
>> // adding 2 components
>>
>> add(component a);
>>
>> add(component b);
>>
>> }
>>
>>
>>
>>
>>
>> public class MyExtPanel extends MyPanel {
>>
>> // add additional 2 components
>>
>> add(component c);
>>
>> add(component d);
>>
>> }
>>
>>
>>
>> I've copied the markup form MyPanel.html to MyExtPanel.html (and added
>> the markup for the additional 2 components).  I'm getting the error:
>> unable to find component hierarchy does not match.  I sort of think I
>> understand why I'm getting the error but can someone explain the "wicket
>> way" of basically extending a panel to add additional components?
>>
>>
>>
>> Thanks,
>>
>>
>>
>> Matt
>>
>>
>>
>>
>

---------------------------------------------------------------------
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