Taken from
http://tapestry.apache.org/tapestry5/tapestry-core/guide/rendering.html


   Rendering Components

Instead of returning true or false, a render phase method may return a component. The component may have been injected via the Component <http://tapestry.apache.org/tapestry5/tapestry-core/guide/.../apidocs/org/apache/tapestry/annotations/Component.html> annotation, or may have been passed to the as a parameter.

In any case, returning a component will queue that component to be rendered *before* the active component continues rendering.

The component to render may even be from a completely different page of the application.

Recursive rendering of components is not allowed.

This technique allows the rendering of Tapestry pages to be /highly/ dynamic.

Returning a component instance does *not* short circuit method invocation, the way returning a boolean would. It is possible that multiple methods may return components (this is not advised -- insanity may ensue).



johnowenatala a écrit :
Hi, i have a place in a page where i wanna put a component, but which
component is desided in runtime (can be from configuration or from request
parameters).
I tried to do this by putting a delegate component, but i couldn't inject in
runtime an unknowed component in compilation time.
What do you think i can do? Is this possible?


--
Michael Courcy
http://courcy.blogspot.com


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

Reply via email to