How does a nested tag get the current state of it's parent? - Weblogic

This is a discussion on How does a nested tag get the current state of it's parent? - Weblogic ; Hi, I have a custom Tag A nested in another custom tag B. B is an iteration tag over a collection of beans. I want tag A to act on each bean in the collection of tag B separately. So ...

+ Reply to Thread
Results 1 to 4 of 4

Thread: How does a nested tag get the current state of it's parent?

  1. How does a nested tag get the current state of it's parent?

    Hi,
    I have a custom Tag A nested in another custom tag B. B is an
    iteration tag over a collection of beans. I want tag A to act on each
    bean in the collection of tag B separately. So while processing A, I
    need a way to get a pointer on the current bean of the collection for
    each iteration of tag B. How can I possibly achieve that?

    Thanks for any help!

    Jonathan

  2. Re: How does a nested tag get the current state of it's parent?

    Jonathan wrote:
    > Hi,
    > I have a custom Tag A nested in another custom tag B. B is an
    > iteration tag over a collection of beans. I want tag A to act on each
    > bean in the collection of tag B separately. So while processing A, I
    > need a way to get a pointer on the current bean of the collection for
    > each iteration of tag B. How can I possibly achieve that?
    >
    > Thanks for any help!
    >
    > Jonathan

    Heres a link to an example for IterationTag

    http://www.onjava.com/pub/a/onjava/2.../07/jsp12.html

    Basically, assuming that tag B exposes a variable (either through the
    tld by using the element or through the VariableInfo[] from
    the TagExtraInfo class for tagB) called say 'currentItem' then it can be
    used as the attribute for tagA i.e

    <%@ taglib uri="/WEB-INF/foo.tld" prefix="foo" %>



  3. Re: How does a nested tag get the current state of it's parent?

    Nagesh Susarla wrote in message news:<3f15b20f@newsgroups.bea.com>...
    > Jonathan wrote:
    > > Hi,
    > > I have a custom Tag A nested in another custom tag B. B is an
    > > iteration tag over a collection of beans. I want tag A to act on each
    > > bean in the collection of tag B separately. So while processing A, I
    > > need a way to get a pointer on the current bean of the collection for
    > > each iteration of tag B. How can I possibly achieve that?
    > >
    > > Thanks for any help!
    > >
    > > Jonathan

    > Heres a link to an example for IterationTag
    >
    > http://www.onjava.com/pub/a/onjava/2.../07/jsp12.html
    >
    > Basically, assuming that tag B exposes a variable (either through the
    > tld by using the element or through the VariableInfo[] from
    > the TagExtraInfo class for tagB) called say 'currentItem' then it can be
    > used as the attribute for tagA i.e
    >
    > <%@ taglib uri="/WEB-INF/foo.tld" prefix="foo" %>
    >
    >
    >

  4. Re: How does a nested tag get the current state of it's parent?


    "Jonathan" wrote in message
    news:d93b54d2.0307220653.33feab6a@posting.google.c om...
    > Nagesh Susarla wrote in message

    news:<3f15b20f@newsgroups.bea.com>...
    > > Jonathan wrote:
    > > > Hi,
    > > > I have a custom Tag A nested in another custom tag B. B is an
    > > > iteration tag over a collection of beans. I want tag A to act on each
    > > > bean in the collection of tag B separately. So while processing A, I
    > > > need a way to get a pointer on the current bean of the collection for
    > > > each iteration of tag B. How can I possibly achieve that?
    > > >
    > > > Thanks for any help!
    > > >
    > > > Jonathan

    > > Heres a link to an example for IterationTag
    > >
    > > http://www.onjava.com/pub/a/onjava/2.../07/jsp12.html
    > >
    > > Basically, assuming that tag B exposes a variable (either through the
    > > tld by using the element or through the VariableInfo[] from
    > > the TagExtraInfo class for tagB) called say 'currentItem' then it can be
    > > used as the attribute for tagA i.e
    > >
    > > <%@ taglib uri="/WEB-INF/foo.tld" prefix="foo" %>
    > >
    > >
    > >