SAP NetWeaver AS ABAP Release 740, ©Copyright 2014 SAP AG. All rights reserved.
ABAP Keyword Documentation → ABAP − Reference → Data Interfaces and Communication Interfaces → ABAP and XML → Transformations for XML → Simple Transformations → ST - Serialization and Deserialization → ST - Transformation of ABAP Values → ST - tt:value, Elementary Data Objects →ST - map, Mapping List
Syntax
... map="..., val(a1, a2, ...) > xml(x), ..." ...
... map="..., xml(x1, x2, ...) > val(a), ..." ...
... map="..., val(a) = xml(x), ..." ...
... map="..., xml(x) = val(a), ..." ...
Effect
You use the map attribute to declare a mapping list for tt:value, tt:write, and tt:read. You do this to map a list of explicitly specified values to precisely one value when serializing or deserializing. A mapping list consists of a single mapping rule or a comma-delimited list of multiple mapping rules. The following mapping rules are possible:
The values a, a1, a2, ... must be specified in accordance with the representation of ABAP values. The XML values x, x1, x2, ... must be put in quotation marks.
Note
If mapping rules with more than one argument are used, transformation is usually no longer symmetrical.
Example
Serialization of ABAP data using a mapping list:
The transformation is not symmetrical. In the following ABAP program, field1 and field2 contain the value "Person" after deserialization.