Hani
Thanks for the reply. I did take a look at CDList
class and the one thing thats puzzling me is that in
the doStartTag and doAfterBody of IteratorTag, all its
doing is a iterator.next() which should return a
Object. My problem is how does that automatically get
cast down to a CD Class. 
I come from a Struts background and in that case, the
logic:iterate has a type attribute which specifies
what is the type of the individual elements in a
Collection.  I couldnt find a similar match in
Webwork.

Thanks
Raj

--- Hani Suleiman <[EMAIL PROTECTED]> wrote:
> have a look at the webwork.examples.i18n.CDList
> class. That is the 
> action class, so when the page makes a call to
> CDList, that 
> automatically calls the getCDList method in that
> action class. The 
> CDList is now iterated through and within the
> iterate block, the top of 
> the value stack now has the current CD at the top,
> so when the 
> propertytag tries to display 'album', the method
> called will be 
> getAlbum() on the particular CD that the iterator
> now points at.
> 
> On Nov 18, 2003, at 8:25 PM, Rajagopal. V wrote:
> 
> > Hello
> > I just started looking at Webwork and checking out
> the
> > examples. One thing i noticed in cdlist.jsp is
> this
> > code
> >    <webwork:iterator value="CDList">
> >    <option value="<webwork:property
> value="album"/>">
> >       <webwork:property value="album"/>,
> >       <webwork:property value="artist"/>,
> > <webwork:property value="country"/>,
> >       <webwork:text name="'price'"
> > value0="@pricer/computePrice(price)"/>
> >    </option>
> >    </webwork:iterator>
> >
> > CDList is actually a List of "CD" objects, but i
> > couldnt find anywhere in the code where this cast
> is
> > made back. So how does webwork know which object
> to
> > call when the getAlbum() is called?
> >
> > TIA
> > Raj
> >
> > __________________________________
> > Do you Yahoo!?
> > Protect your identity with Yahoo! Mail
> AddressGuard
> > http://antispam.yahoo.com/whatsnewfree
> >
> >
> >
>
-------------------------------------------------------
> > This SF.net email is sponsored by: SF.net Giveback
> Program.
> > Does SourceForge.net help you be more productive? 
> Does it
> > help you create better code?  SHARE THE LOVE, and
> help us help
> > YOU!  Click Here: http://sourceforge.net/donate/
> > _______________________________________________
> > Opensymphony-webwork mailing list
> > [EMAIL PROTECTED]
> >
>
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
> >
> 
> 
> 
>
-------------------------------------------------------
> This SF.net email is sponsored by: SF.net Giveback
> Program.
> Does SourceForge.net help you be more productive? 
> Does it
> help you create better code?  SHARE THE LOVE, and
> help us help
> YOU!  Click Here: http://sourceforge.net/donate/
> _______________________________________________
> Opensymphony-webwork mailing list
> [EMAIL PROTECTED]
>
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork


__________________________________
Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard
http://antispam.yahoo.com/whatsnewfree


-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
_______________________________________________
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork

Reply via email to