icomponentresolver does exactly what its javadoc says - match markup tags to components. if you want you can create those components on the fly - but remember that this happens at render time so it might have some side effects for you.
you dont need to rewrite your panel as a component resolver and add it to application settings - not many global component resolvers make sense unless you use namespaced markup tags. instead it is most times easier to simply let your component implement the interface directly - it works that way too. if you want to see how it is meant to be used then simply search our codebase for references to it. -igor On Dec 5, 2007 7:15 AM, Matthijs Wensveen <[EMAIL PROTECTED]> wrote: > Hello, > > I have developed a panel named AutoComponentPanel that automatically adds > wicket components based on (dynamic) markup. Looking at IComponentResolver I > noticed some similarities. Can someone explain this class and its uses to me? > Is it > something that I should want to use for AutoComponentPanel? > > We use AutoComponentPanel as a base class for some other panels that > provide dynamic markup. For example transformed xml (xml -> xslt -> xhtml + > wicket:id attributes). > Would it be better (aka the wicket-way (tm)) > when AutoComponentPanel is re-written as an IComponentResolver that can > be used by the currently subclassing panels? They would then need to > implement IComponentResolver too but can call my rewritten > AutoComponentPanelAsResolverSomething in their implementing methods. > > Would this be a better way to go? > > How should this work when I add my resolver with > Application.getPageSettings().addComponentResolver(resolver)? > > Thanks, > Matthijs Wensveen > > -- > Matthijs Wensveen > Func. Internet Integration > W http://www.func.nl > T +31 20 4230000 > F +31 20 4223500 > > --------------------------------------------------------------------- > 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]
