How about this?...

<j:set var="path" trim="true">
    default.jar;
    <j:forEach var="dep" items="${pom.dependencies}">
        ${dep.artifactId};
    </j:forEach>
<j:set>
<echo>${path}</echo>


James
-------
http://radio.weblogs.com/0112098/
----- Original Message -----
From: "Paul Libbrecht" <[EMAIL PROTECTED]>
To: "Jakarta Commons Users List" <[EMAIL PROTECTED]>
Sent: Tuesday, January 28, 2003 3:54 PM
Subject: Re: [Jelly] Concatenate variable values or strings


You can certainly make more elegant things but I fear it would require
extensions of Jelly. One interesting thing would be to be able to
convert a list of XPath result-nodes into a string with appropriate
separators (presumably of any iterator convertible)... someone should
volunteer for such a tag in util.

Paul


Le Mardi, 28 janv 2003, � 11:14 Europe/Berlin, Rademacher Tobias a
�crit :
> I want to get a java classpath into a long string sepearted by ;.
> The path consists of all maven dependencies. Is there a easier/better
> way to
> concatenate the string than this:
>
> <j:set var="path" value="default.jar;"/>
> <j:forEach var="dep" items="${pom.dependencies}">
>   <j:set var="path" trim="true">
>     ${path}${dep.artifactId};
>   </j:set>
> </j:forEach>
> <echo>${path}</echo>
>
> I just want to write good jelly code. :-)
>
> Bye
> Toby
>
> --
> To unsubscribe, e-mail:
> <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
> <mailto:[EMAIL PROTECTED]>
>


--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to