You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Jelena Jovanovic <jo...@fon.bg.ac.yu> on 2005/06/29 12:57:43 UTC
Setting custom rendering for a component
Hello everyone!
I need to create a component to represent content of a list. Since the
list's content and structure (if it has sub-lists or not) are not static
(determined during the run time), I suppose that I have to define custom
rendering for my component. I assume that I have to override some Tapestry's
methods for component rendering, but I do not know which ones. Can someone
help, please?
Regards,
Jelena
Re: Setting custom rendering for a component
Posted by Robert Zeigler <ro...@scazdl.org>.
Norbert Sándor wrote:
> 1. if your component extends AbstractComponent, then you should
> implement renderComponent()
> 2. if your component extends BaseComponent then you should use a
> template instead of overriding renderComponent()
If necessary, by extending BaseComponent, you can use both a template
and hard-coded rendering; just remember to call super.renderComponent at
an appropriate point. :)
Robert
>
> I would try the second, BaseComponent with a template (without custom
> rendering) if it is possible. Even very complex custom components can be
> created this way by using Foreach,Conditional,Block,RenderBlock.
>
> Br,
> Norbi
>
> ----- Original Message ----- From: "Jelena Jovanovic"
> <jo...@fon.bg.ac.yu>
> To: <ta...@jakarta.apache.org>
> Sent: Wednesday, June 29, 2005 12:57 PM
> Subject: Setting custom rendering for a component
>
>
>> Hello everyone!
>>
>> I need to create a component to represent content of a list. Since the
>> list's content and structure (if it has sub-lists or not) are not static
>> (determined during the run time), I suppose that I have to define custom
>> rendering for my component. I assume that I have to override some
>> Tapestry's
>> methods for component rendering, but I do not know which ones. Can
>> someone
>> help, please?
>>
>> Regards,
>> Jelena
>>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
RE: Setting custom rendering for a component
Posted by Jelena Jovanovic <jo...@fon.bg.ac.yu>.
Thanks!!!!
Regards,
Jelena
-----Original Message-----
From: Norbert Sándor [mailto:developer@erinors.com]
Sent: 29 June 2005 13:13
To: Tapestry users
Subject: Re: Setting custom rendering for a component
1. if your component extends AbstractComponent, then you should implement
renderComponent()
2. if your component extends BaseComponent then you should use a template
instead of overriding renderComponent()
I would try the second, BaseComponent with a template (without custom
rendering) if it is possible. Even very complex custom components can be
created this way by using Foreach,Conditional,Block,RenderBlock.
Br,
Norbi
----- Original Message -----
From: "Jelena Jovanovic" <jo...@fon.bg.ac.yu>
To: <ta...@jakarta.apache.org>
Sent: Wednesday, June 29, 2005 12:57 PM
Subject: Setting custom rendering for a component
> Hello everyone!
>
> I need to create a component to represent content of a list. Since the
> list's content and structure (if it has sub-lists or not) are not static
> (determined during the run time), I suppose that I have to define custom
> rendering for my component. I assume that I have to override some
> Tapestry's
> methods for component rendering, but I do not know which ones. Can someone
> help, please?
>
> Regards,
> Jelena
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: Setting custom rendering for a component
Posted by Norbert Sándor <de...@erinors.com>.
1. if your component extends AbstractComponent, then you should implement
renderComponent()
2. if your component extends BaseComponent then you should use a template
instead of overriding renderComponent()
I would try the second, BaseComponent with a template (without custom
rendering) if it is possible. Even very complex custom components can be
created this way by using Foreach,Conditional,Block,RenderBlock.
Br,
Norbi
----- Original Message -----
From: "Jelena Jovanovic" <jo...@fon.bg.ac.yu>
To: <ta...@jakarta.apache.org>
Sent: Wednesday, June 29, 2005 12:57 PM
Subject: Setting custom rendering for a component
> Hello everyone!
>
> I need to create a component to represent content of a list. Since the
> list's content and structure (if it has sub-lists or not) are not static
> (determined during the run time), I suppose that I have to define custom
> rendering for my component. I assume that I have to override some
> Tapestry's
> methods for component rendering, but I do not know which ones. Can someone
> help, please?
>
> Regards,
> Jelena
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org