I've spent some time looking through the Portal tutorial and it uses a
"model" to determine the content for each portal window. The model uses
IRequestCycle to get a page, and then get the block. Is there a way to
get a component, declared through component-alias, directly without
putting it on a page - or do I create a page of cell renderers and pull
the blocks from it, getting the nested components and setting their
values?

Richard Hyatt
[EMAIL PROTECTED]


-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] 
Sent: Wednesday, September 11, 2002 12:00 PM
To: Richard Hyatt
Cc: Tapestry Developer
Subject: Re: [Tapestry-developer] Using Components to render table cells


One option to investigate is the Block and RenderBlock 
components.

Blocks allow you to pass HTML and other components 
almost as if they were parameters.

It's actually pretty simple; A Block doesn't render its 
body until a RenderBlock forces it to.  Thus you can 
take a parameter of type Block and feed it to a 
RenderBlock (inside your table component).

The Palette uses Blocks for the headers above the 
available and selected columns.  The default Blocks it 
uses are simple HTML, but you can pass in something more 
complex if you want.

Blocks have also been used in the Portal tutorial.

The Action and Direct service are smart ... they adjust 
to cases where the component is from a different page 
than the render page (dragged in by a RenderBlock).  
Just like magic!

--
[EMAIL PROTECTED]

http://tapestry.sf.net
> I am trying to create a table component that can use a custom renderer

> for each cell, based upon a table model - similar to java's swing. 
> I've read through Mind Bridge's email about creating generic 
> components, but it left off how to include components. I'm interested 
> in including existing components dynamically or through inclusion in 
> the jwc that defines the place where the component is used. I've tried

> using Delegator's but I'm unsure how to create or get a component 
> outside of my generic component.
>  
> Can anyone point me in the right direction to get this working (either

> through Delegators or another means).
>  
> Thanks,
>  
> Richard Hyatt
> [EMAIL PROTECTED]
>  
> 


-------------------------------------------------------
In remembrance
www.osdn.com/911/
_______________________________________________
Tapestry-developer mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/tapestry-developer

Reply via email to