velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Matthias Hendler" <hendl...@gmx.de>
Subject Putting key/value pair into hashmap from velocity template
Date Wed, 19 Jul 2006 14:54:17 GMT
Hello,

I try to put a key/value pair to a hashmap from velocity template.

First I put a new hashmap object into velocity context named "myMap".
In my templates I can write:
...
$myMap.clear()
Size: $myMap.size()
...
The above works fine. Now I want to put a key/value pair into the hashmap using the method
put(object, object).

So I wrote:
...
${myMap.put(["123", "test"])}
...
And I get an exception: "${myMap.put(["123", "test"])} is not a valid reference."

What's wrong?

Thanx 
Matthias









-- 


Der GMX SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen!
Ideal für Modem und ISDN: http://www.gmx.net/de/go/smartsurfer

---------------------------------------------------------------------
To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: velocity-user-help@jakarta.apache.org


Mime
View raw message