Can you do something like this in a velocity template?
#set ($map = $myobject.getMap() ) #foreach ($mapEntry in $map.entrySet()) $mapEntry.key()&
To clarify (I cannot comment), in general you can use either the Java get methods, or replace them by the corresponding name without with a small letter and without ().
()
So $mapEntry.getKey() or map.key.
$mapEntry.getKey()
map.key