Data Type Map

From emotive
Jump to: navigation, search

Classification

Name Map
Short Description Collection of key-value pairs of the same type
Class Simple Data Type
Base Data Type ComplexType
Default Value An empty map
Provide a Literal Yes
SpecifiedBy ISO 13209-2
Standard Compliant Yes

Description

The Map data type identifies OTX in a number of zero or more key-value pairs. When you declare the type of the key and the type of the value must be specified. Within a Map keys must be unique. Via the key is accessed, the values ​​in the map.

Core Conversion

The following table shows the rules for conversion to another data type:

Conversion Result Sample
ToBoolean Undefined (should not be used)
ToInteger Undefined (should not be used)
ToFloat Undefined (should not be used)
ToString Returns the map as a string String s = ToString({1:true, 2:false, 3:true}); // Returns "{1:true, 2:false, 3:true}"
ToByteField Undefined (should not be used)

Sample

Map<Integer, Boolean> MapVariable = {1:true, 2:false, 3:true};