Versiones comparadas

Clave

  • Se ha añadido esta línea.
  • Se ha eliminado esta línea.
  • El formato se ha cambiado.

Transacción Transaction /EDGE/FC_SPRO → Carpeta de configuración "Transformaciones".

A través de esta opción es posible realizar el mapeo del XML a estructuras ABAP.

Parte de la base que previamente se importó el XSD, del XML que se quiere transformar, dentro de un WSDL a la instancia ABAP como un proxy ABAP. El procedimiento es el siguiente:

...

SPRO -> Configuration Folder "Transformations".

Through this option, it is possible to perform the mapping of XML to ABAP structures.

It is assumed that the XSD of the XML to be transformed has been previously imported into a WSDL and then into the ABAP instance as an ABAP proxy. The procedure is as follows:

  • Import the XML definition, i.e. the XSD, as a WSDL to the SAP system, so that the necessary proxies are created as if a service were being published. This activity is only performed once and must be transported to each environment. The idea is that the ABAP Framework generates a class and an interface with a method, where the only parameter to the method is the XML definition itself. In this way standard tools would be used to deserialise the XML and put it into a simpler ABAP structure.

El proxy creado, genera una estructura ABAP de entrada al método; esa estructura es la que se utiliza para recorrer el XML y para configurar el mapeo.

Para tener más claridad al respecto, a continuación se muestra el proxy creado para la facturación electrónica de Costa Rica, donde se crearon varias operaciones en el WSDL, cada una con un XML que se utilizaría dentro del proceso tanto de emisión como de recepción:

Image Modified

Image Modified

Para el caso de recepción donde se utiliza la transformación XML, se generó la siguiente estructura:

...