DSP tags can use var

Posted by wsargent Mon, 14 Mar 2005 06:42:00 GMT

Ah-ha. I was wrong about DSP not being EL aware. It can write out var attributes, it just can’t read them.

”[…] both tag libraries are derived from the same fundamental code: how a tag permits access to data (EL or runtime expressions) is an implementation detail defined in the TLD. Both tag libraries support a var attribute for the dspel:tomap tag so both dsp:tomap and dspel:tomap are able to create a Profile attribute that represents the Profile component in pageScope - only DSPEL tags can reference that attribute. The use of dspel:tomap here doesn’t include EL or runtime expressions so the tasks it accomplishes might be done with either the DSP or DSPEL version of the tag. In short, it is acceptable to use DSP tags to create attributes that enable DSPEL or JSTL tag operations.” [link]

Which means that things like this:

<dsp:tomap var="profile" bean="/atg/userprofiling/Profile" recursive="true"/>

are actually kosher. Cool.

Leave a comment

Comments