tomcat-taglibs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Simon Benzekri" <s.benze...@PENSON.CA>
Subject RE: [JSTL] Indexed array variable
Date Wed, 02 Jun 2004 14:10:23 GMT
Good idea but how will multi-dimensional arrays be populated?


-----Original Message-----
From: Helios Alonso [] 
Sent: Wednesday, June 02, 2004 9:48 AM
To: Tag Libraries Users List
Subject: RE: [JSTL] Indexed array variable

It would be great.  I think it's very appropiate (very common idea even for 
non-programmers, easy to implement).

By example (my case):  I want to make a calendar and would like to make it 
very generical.  If I could use associations with taglibs, I'd make 
something that gives me dates (or months, weeks, and days), and another 
bean associating days to properties.  It helps mantaining the calendar code 
independent from the "properties" code.  And properties could be 
associations too:

'holiday' -> boolean
'holidayname' -> name
'itemscount' -> int

and so on.

The JSP would poduce HTML for the calendar, but guided by the properties of 
each day (holidays in red, days with items with a link, etc.)

At 09:25 02/06/2004 -0400, you wrote:
>I think you're right.  Just like no JSTL tag exists to create an
>associative array (a bean or a map indexed by string), no JSTL tag
>exists that can explicitly allocate an indexed array.  <jsp:useBean> can
>create both associative and indexed arrays, and <c:set> can set
>associative array properties, but not indexed array elements.  I think
>the only solution, then, is to create my own tag handler similar to
><c:set> that can assign array elements.  Of course, this is
>non-standard, but will solve my problem.
>Will the next version of JSTL enhance <c:set> to permit the assignment
>of array elements?
> > -----Original Message-----
> > From: Bill Siggelkow []
> > Sent: June 1, 2004 8:49 PM
> > To: 'Tag Libraries Users List'
> > Subject: RE: [JSTL] Indexed array variable
> >
> >
> > I don't think that JSTL is going to be able to "create" array
> > elements. I think you will need to allocate the array ahead
> > of time. Maybe someone else can clarify this a little more.
> >
> >
> > Bill Siggelkow
> >
> >
> >
> > -----Original Message-----
> > From: Derek Mahar []
> > Sent: Tuesday, June 01, 2004 5:10 PM
> > To: Tag Libraries Users List
> > Subject: [JSTL] Indexed array variable
> >
> > How does one create and assign elements to an indexed array
> > variable in JSTL or the Expression Language? <c:set> seems
> > lacking in this respect.
> >
> > Derek
>NOTICE: This email contains privileged and confidential information and is 
>intended only for the individual to whom it is addressed. If you are not 
>the named addressee, you should not disseminate, distribute or copy this 
>e-mail. Please notify the sender immediately by e-mail if you have 
>received this transmission by mistake and delete this communication from 
>your system. E-mail transmission cannot be guaranteed to be secured or 
>error-free as information could be intercepted, corrupted, lost, 
>destroyed, arrive late or incomplete, or contain viruses.
>AVIS: Le présent courriel contient des renseignements de nature 
>privilégiée et confidentielle et n'est destiné qu'à la personne à qui il 
>est adressé. Si vous n'êtes pas le destinataire prévu, vous êtes par les 
>présentes avisés que toute diffusion, distribution ou reproduction de 
>cette communication est strictement interdite.  Si vous avez reçu ce 
>courriel par erreur, veuillez en aviser immédiatement l'expéditeur et le 
>supprimer de votre système. Notez que la transmission de courriel ne peut 
>en aucun cas être considéré comme inviolable ou exempt d'erreur puisque 
>les informations qu'il contient pourraient être interceptés, corrompues, 
>perdues, détruites, arrivées en retard ou incomplètes ou contenir un virus.
>To unsubscribe, e-mail:
>For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message