Say you have
        <x:loop on="object">
         FOO
         <x:insertLoopDependentValue/>
         BAR
        </x:loop>

With semantcs that x:loop will generate a stream that is a sequence of
its body, reevaluated every time with a new LoopDependentValue.  I.e.,
it is of the form

... FOO -1st time value- BAR..FOO -2nd time value- BAR..FOO -last time-
BAR ...

Your LoopHandler.doAfterBody method cannot reevaluate its Body.  It can
perform any action it wants, including iterating over structures, etc,
but the only way it could reevaluate the body is if it had access to the
body >pre-evaluation<, and if it had access to an "eval()" function, and
if it had access to the appropriate closure on the evaluation context.
We designed the tag extension mechanism to impose minimal constraints on
the implementation strategy of JSPs, so we have this "inside-out"
mechanism.

Hope this helps,
        - eduard/o

> Date:    Sat, 5 Feb 2000 09:09:04 -0000
> From:    Kevin Jones <[EMAIL PROTECTED]>
> Subject: Re: Point of EVAL_BODY_TAG
>
> Yes - I know it's for looping but that still doesn't explai the point - I
> could just as easily do this
>
> public int soAfterBody()
> {
>         while(bNotDone)
>         {
>         }
>         return SKIP_BODY
> }
>
> I don't need EVAL_BODY_TAG to let me loop!!!!
>
> Kevin Jones
> DevelopMentor

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
FAQs on JSP can be found at:
 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html

Reply via email to