Ansicht
Dokumentation

ABENRPM_DERIVED_TYPES - RPM DERIVED TYPES

ABENRPM_DERIVED_TYPES - RPM DERIVED TYPES

CL_GUI_FRONTEND_SERVICES - Frontend Services   ROGBILLS - Synchronize billing plans  
This documentation is copyright by SAP AG.
SAP E-Book

ABAP for RAP, BDEF Derived Types

BDEF derived types are special data types in the context of RAP. The types are derived by the ABAP runtime framework from CDS entities and their behavior definition in the BDEF. In general, BDEF derived types are used in ABAP to enable a type-safe access to RAP BOs. As an essential part of RAP, internal tables and structures that are typed with BDEF derived types are used for the communication and to exchange data between RAP BO consumers and RAP BO providers, thus, allowing mass processing of data.

Each BDEF derived type can be categorized as input or output (result) derived type according to its use as import or export parameter in methods of RAP BO providers. For example, the types ... FOR CREATE ... or ... FOR UPDATE ... are used for providing input; ... FOR READ RESULT ..., ... FOR ACTION RESULT ... or ... FOR FAILED ... are used to return a result.

Internal tables and structures that are typed with BDEF derived types contain components of CDS entities like key and data fields that retain their original line type. Yet, BDEF derived types also contain additional RAP components that do not derive their line type from the entity. They have special, tailor-made line types that provide additional information required in the context of transactional processing. The names of those RAP components begin with % to avoid naming conflicts with components of the CDS entities. Among the components, there are component groups available summarizing groups of table columns under a single name. In doing so, they simplify the handling of derived types for developers. For example, %key summarizes all primary keys. For details on the components, see the topic Components of BDEF Derived Types.

The parameters of RAP BO operations are mainly typed with BDEF derived types. Derived types can also be used outside of those operations in ABAP programs using ABAP EML. They can be explicitly declared using a variable, for example, with the statements TYPES, DATA and CREATE.

Derived types can be declared using the following variants:

Notes

  • BDEF derived types are created automatically and known to the ABAP compiler only. The element information, for example, for a variable typed with a BDEF derived type can be called choosing F2 in ADT to display the components.






Addresses (Business Address Services)   General Material Data  
This documentation is copyright by SAP AG.

Length: 4106 Date: 20240427 Time: 024239     sap01-206 ( 73 ms )