Once the business object data is converted into a flat structure, the business object data is passed into SAP memory by calling the adapter's ABAP function module /CWLD/RFC_DO_VERB_NEXTGEN. /CWLD/RFC_DO_VERB_NEXTGEN does not manipulate the business object data; it simply routes it to the appropriate ABAP handler for further processing. After /CWLD/RFC_DO_VERB_NEXTGEN passes the business object data to an ABAP handler, it waits for business object data to be returned.
/CWLD/RFC_DO_VERB_NEXTGEN uses a business object's verb application-specific information to determine which ABAP handler processes the business object data. At runtime, /CWLD/RFC_DO_VERB_NEXTGEN reads the verb application-specific information and passes the business object data to the specified ABAP handler.
Every ABAP handler must reserve the use of verb application-specific information for the connector. The format for the verb application-specific information is:
:function1:function2:function3
where /CWLD/RFC_DO_VERB_NEXTGEN executes function1, passing function2 and function3 as parameters. For example, Customer Update and Material Retrieve execute only function1:
For Create, Update, and Delete verbs, specify:/CWLD/RFC_DYNAMIC_TRANSACTION
For the Retrieve verb, specify:/CWLD/RFC_DYNAMIC_RETRIEVE
One of the ABAP handlers provided by the adapter is function module /CWLD/IDOC_HANDLER. This ABAP handler reformats the data of the flat structure into an instance of an IDoc definition and passes that reformatted data to another ABAP handler written to handle that specific type of IDoc. The following examples illustrate the use of the IDoc Handler API:
Sales Order Update = :/CWLD/IDOC_HANDLER:Y_XR_ORDER_C2
Sales Order Retrieve = :/CWLD/IDOC_HANDLER:Y_XR_ORDER_C4
In the examples, /CWLD/IDOC_HANDLER is executed and passes the second function module name as well as the business object data. /CWLD/IDOC_HANDLER executes the call to the second ABAP handler to pass the business object data in an IDoc format to the Y_XR_ORDER_C2 or Y_XR_ORDER_C4 function module written specifically to handle Order objects.
To dynamically call an ABAP handler, /CWLD/RFC_DO_VERB_NEXTGEN requires the interface of every ABAP handler to be exactly the same. This enables /CWLD/RFC_DO_VERB_NEXTGEN to send and receive business object data, as well as a return code and a return text message to any ABAP handler. For more information on the functional module interface, see IBM WebSphere function module interface.