SAP NEWS-610-TYPEN

Get Example source ABAP code based on a different SAP table
  



Type Concept in Release 6.10

1 Constants for structures and internal tables
2 New generic types for field symbols and formal parameters
3 Methods for displaying specific properties of types
4 Type description objects for all friends of a class

ABAP_MODIFICATION_1 Constants for Structures and Internal Tables


Constants can now be defined for structures and internal tables, which in turn contain internal tables or references and strings. Only the initial value is possible however.

Example ABAP Coding
types:
begin of STRUC,
ITAB type standard table of SPFLI with non-unique key CARRID,
MREF type ref to OBJECT,
end of STRUC.

constants:
CONST type STRUC value is initial.

ABAP_MODIFICATION_2 New Generic Types for Field Symbols and Formal Parameters


The new generic types can be used for typing field symbols and parameters in subroutines, function modules, or methods. The following table shows their variants: Gen. TypeTypes SIMPLECLIKE, XSEQUENCE, NUMERIC CLIKEN, D, T, STRUC1, CSEQUENCE CSEQUENCEC, STRING XSEQUENCEX, XSTRING NUMERICI, s, b, P, F

ABAP_MODIFICATION_3 Methods for Displaying Specific Properties of Types


The method GET_PROPERTY, which provides information on specific type properties at runtime, has been added to the class CL_ABAP_TYPEDESCR.

ABAP_MODIFICATION_4 Type Description Objects for All Friends of a Class


The method GET_FRIEND_TYPES was introduced in the classs CL_ABAP_CLASSDESCR. This can be used to query the type description objects for all friends of a class at runtime.