You can use either the XML Object syntax or XPRESS to dynamically construct Map objects. Using the XPRESS <map> element is similar to using the XML Object language <Map> and <MapEntry> elements. These elements differ in that the contents of <map> can be calculated using expressions. In contrast, the <Map> element can only define static maps.
Maps are sometimes used as arguments to methods that are called with an <invoke> expression. For example, certain methods in the FormUtil class require maps as arguments.
The contents of the XPRESS <map> element are pairs of name/value expressions. The even-numbered expressions define map keys, and odd-numbered expressions define map values. If any key expression evaluates to null, the entry is ignored.
You can use the XPRESS <map> element to dynamically construct java.util.HashMap objects:
<map> <s>name</s> <s>Jeff</s> <s>phone</s> <s>338-1818</s> </map>
You can use XML Object syntax to define map objects as follows:
<Map> <MapEntry key=’name’ value=’Jeff’/> <MapEntry key=’phone’ value=’338-1818’/> </Map>