I have an Ajax event that triggers the redraw of various Wicket panels. Some panels have additional calculations of their own inside their onBeforeRender() method. If there is a
Getting the AjaxTarget
is done like this:
AjaxRequestTarget target = requestCycle.find(AjaxRequestTarget.class);
Unfortunately, like expected, I can't add components to the target once I'm in the rendering phase. But Wicket provides the interface ITargetRespondListener with the method onTargetRespond(AjaxRequestTarget target)
. Here I can add anything I want to the target.