I thought that one out, but I see it dificult to extend in the
future...

As far as I undestand (which is not much) the Blocks definitions must
be on the template of the component so... adding support for some
class involves adding a block definition to the template and some
association in some other place between the class and the Block name.

It would be great if in place of adding a Block to the template of the
component, you could add another independent component and the
association between the new component and the class.

So the component could be on a predefined not-to-be-touched library,
and when you must add support for some class in some application you
can just build the new component and register the association.

Do you see any way to accomplish this?

The ability to programatically add components to a page/component (like
you can do with Swing or CLX) would be great for building really dynamic
interfaces with Tapestry.

Is there a way to support this on Tapestry?

-- 
Saludos,
 Pablo                          mailto:[EMAIL PROTECTED]

> Message: 4
> From: "Howard M. Lewis Ship" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Subject: Re: [Tapestry-developer] dynamic component selection
> Date: Thu, 26 Sep 2002 06:28:48 -0400
> 
> The approach I would use is to use Block/RenderBlock.  You use some kind of
> table ot map from objects to the names of Blocks used to render the object
> (check out the AdaptorRepository class).
> 
> 
> 
> ----- Original Message -----
> From: "Pablo I. Lalloni" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Thursday, September 26, 2002 4:19 AM
> Subject: [Tapestry-developer] dynamic component selection
> 
> 
>> I am working on an generic CRUD component for Tapestry.
>>
>> For this component to work you have to supply it with an "access
>> delegate" which is responsable for the basic CRUD operations on the
>> dataset and also responsable for providing the actual data (as a List
>> of Object) to be rendered by the component.
>>
>> Now I face the problem of rendering the List in the page.
>>
>> My first thinking was about some way of registering "renderers" for
>> classes, so the G-CRUD component would find a renderer component for
>> the class X and put it on the response for rendering the n-object from
>> the list. This renderer components should have all an "object"
>> parameter which should be binded to the object to be rendered.
>>
>> I see that at least 2 kind of renderers are posible, one that shows
>> (represents) an object in some readable way on the client's browser
>> and one that represent the object in an editable way (with an HTML
>> FORM).
>>
>> The first problem I see here is how to dinamically put a component on
>> a Tapestry page?
>> I don't see how this can be done... please someone that knows how to
>> do this tell me.
>>
>> One solution I thought was to make a kind of delegator component that
>> can wrap another component which can be changed at runtime using some
>> parameter of the delegator... very much like the "Delegator" component
>> provided with Tap but instead of giving it an IRender you provide it
>> with a Component alias to be rendered... I don't know if this is
>> posible or how it could be done.
>>
>>
>> --
>> Saludos,
>>  Pablo                          mailto:[EMAIL PROTECTED]
>>
>> "The only thing that interferes with my learning is my education."
>> Albert Einstein
>>
>>
>>
>>
>>
>> -------------------------------------------------------
>> This sf.net email is sponsored by:ThinkGeek
>> Welcome to geek heaven.
>> http://thinkgeek.com/sf
>> _______________________________________________
>> Tapestry-developer mailing list
>> [EMAIL PROTECTED]
>> https://lists.sourceforge.net/lists/listinfo/tapestry-developer
>>





-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Tapestry-developer mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/tapestry-developer

Reply via email to