There is no task.
But you can use the java.lang.String.toUpperCase() method:
<scriptdef name="uc" language="javascript">
<attribute name="property"/>
<attribute name="value"/>
project.setNewProperty(attributes.get("property"),
attributes.get("value").toUpperCase());
</scriptdef>
<uc property="one" value="one"/>
<echo>one = ${one}</echo>
<uc property="one" value="another"/>
<echo>one = ${one}</echo>
<uc property="two" value="Two"/>
<echo>two = ${two}</echo>
[echo] one = ONE
[echo] one = ONE <----- properties are immutable (therefore use of
set_New_Property() )
[echo] two = TWO
Jan
> -----Original Message-----
> From: skalsky@oksystem.cz [mailto:skalsky@oksystem.cz]
> Sent: Tuesday, May 25, 2004 10:53 AM
> To: user@ant.apache.org
> Subject: UpperCase or similar task
>
>
> Hello there,
> I have a problem with strings in ANT. Is there any task
> to make upperCase (or lowerCase) of string in ANT ? I can't
> find anything in the apache.org :(
>
> Thanx 4 your help.
> Milan
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>
|