"> i have concerns about performance "
This is one of the main reason I added output(RenderContext context). The
rational was to "conserve" objects by allowing them to hang around in memory
and change their look and feel to suit different needs. Without it I found I
often had to instantiate a new class for every small difference.
Also, by putting adding a cache to the RenderContext (in the XML user
object) I was able to save more processing time by doing something like
this:
public void output(RenderContext context)
{
XML user =
(XML)context.getRequest().getAttribute(Parameters.user);
ConcreteElement childFolder =
user.getElement("selectedTreeNode).getElement(dataSourcePath);
if(childFolder == null){
//do some really long task that if every user did it would
kill the system
//when done add to the user element
}else{
//save oodles of time here by just returning the cached
result
childFolder.output(context);
}
}
John
----- Original Message -----
From: "robert burrell donkin" <[EMAIL PROTECTED]>
To: "ECS Developers List" <[EMAIL PROTECTED]>
Sent: Wednesday, November 14, 2001 6:15 PM
Subject: Re: Fw: additions to ConcreteElement
> On Wednesday, November 14, 2001, at 06:25 PM, jnilson wrote:
>
> > yes, this allowed me to create re-usable components then parameterized
> > them
> > so they look slightly different depending upon what's in the render
> > context.
> >
> > I find it tremendously powerfull but I must admit its a bit of a hard
> > sell.
>
> hmmmm....
> it does have a kind of perverse logic. it's odd but that doesn't make it
> bad...
>
> i have concerns about performance and concurrency but i'd need more time
> to think to see if they're real.
>
> to be honest i'm very reluctant to commit any changes to the core
> functionality of ecs. i'd have to be very certain to make this type of
> commit without hearing what stephan thinks first.
>
> so i guess at the moment i'm -0 (mainly on gut feeling)
> (that is - i'm not going to commit it but i'm not going to veto it either.
> )
>
> i suggest that you continue with your experiment. ecs is a stable project
> and that means you're unlikely to have to pay a 'stupid tax' (the code's
> not likely to change under you).
>
> if you hang around long enough, then stephan will probably take a look and
> give you the benefit of his wisdom. i might even post some more comments
> and questions when i've thought about it further.
>
> - robert
>
> --
> To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
>
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>