[
  ...cut (there was probably copyright issues with copying
  that much of the spec :)...
]

> 
> I believe these tags are OK. (Disclaimer: I am by no means a nested tags
> expert!) In effect, the nested tags do cache the property values, as you
> suggest they should, just not in the way you might expect. The caching is
> being done by setProperty(), but only if that method is being called by the
> container, and resetting of the original value is being done as the first
> thing in doStartTag().

correct.
*game-show-ding*

All that's been said by both parties is true. The contract for tags for
clarification (for the benefit of those searching mailing lists for problems
to report :)...

Tag A created,
  set property one
  set property two
invoked

Goes to reuse tag A,
  set property one.
  property two is the same on this invocation, so it's not set again,
     the value assumed to still be there from first invocation.
invoked.


...as Martin confirmed, the nested tags store the original setting for the
properties they change, and then do their magic. When the tag is reused, the
original property is restored. As already mentioned, Resin does this to the
letter, and the above is what I had to do to correct the problem. So far
Resin's the best performer for all things nested-taggish.

The tags *could* set the original properties at the end of doEndTag(), but
when it's reused, the logic is sound that it'll be set back again properly
ready to dance. I'll try the pessimistic thing when I get the chance, but on
the surface it sounds like it would only be a problem if Tomcat's doing
something improper after a tag's doEndTag() has been invoked...


Arron.


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

Reply via email to