Start of Content Area

Background documentation Adaptive RFC  Locate the document in its SAP Library structure

The Adaptive Remote Function Call (Adaptive RFC) is a technology that enables the Web Dynpro application developer to use the business functions encapsulated in Business APIs (BAPIs) even after a structure modification, without having to provide the new data using a second back end or a new structure with subsequent regeneration of the proxies.

This new RFC model shows adaptive behavior. This means that the RFC proxies do not use the original design time structure definition at runtime. Instead, this Web Dynpro model automatically adapts the data of the structure passed in the Java proxy generation to the current data – that is, a structure definition in the back-end system that may have been modified.

Generated structures are used for the context definition; the context ensures type-specific access to the attributes, as they are valid at runtime. However, the context attribute does not create the structure attributes until runtime and can therefore automatically take any changes made a later stage into account.

All structures, fields, and data types are maintained by the Java Dictionary runtime. A memory is available for this, which acts like a virtual machine: Load definitions are automatically loaded from the back end on demand.

The Web Dynpro context therefore shows adaptive, non-static behavior. At runtime, not just those fields are visible that were generated at design time. The following modification scenarios show the support offered by the Adaptive RFC in detail:

·        Data types

¡        If a data type is edited in the back-end system, the structure used for the Web Dynpro application remains valid and no runtime error occurs.

·        Customer enhancements and adjustments

¡        If a field length is changed in the back-end system or a customer enhancement field is created, the field values are still valid at runtime. The enhancement field remains visible even without a subsequent manual adjustment of the structure at design time.

·        Release-specific structures

¡        If a structure changes in the back-end system due to a new release – for example, if the application developer adds a new field – no runtime error occurs in the Web Dynpro application.

·        Different structure definitions in different back-end systems

¡        Restriction: No fields or structures may have been deleted in any of these systems.

Field Access

The visibility of enhancement fields using the Adaptive RFC model is achieved by using the generic get/setProperty on the model class.

For the visibility of enhancement fields from within the context use IWDNodeInfo or IWDAttributeInfo. All fields are copied using WDCopyService. To access the enhancement fields, use get/setAttributeValue on the model class.

Example

The following is a code example for a field access:

String getCustomerName()

String getCustomerID()

String getOrderID()

String getQuantity()

BigDecimal getPrice()

String getDiscount()

Object getAttributeValue(“CustomExtension”)

Additional Information

For information on how to use an Adaptive RFC model in a Web Dynpro application, refer to Importing an Adaptive RFC Model.

 

End of Content Area