SAP TYPE NAMES
Get Example source ABAP code based on a different SAP table
Absolute Type Names
The type name of a user-defined (i.e. not built-in) type that can be used statically in ABAP statements is only valid in relation to its context and is therefore also known as the relative type name. As described in
Absolute type names, however, uniquely identify a type. An absolute type name as a path specifications is made up of the following components:
BEGIN_SECTION VERSION 5 OUT
END_SECTION VERSION 5 OUT
BEGIN_SECTION VERSION 5 OUT
END_SECTION VERSION 5 OUT
The last component of a path must always be
Absolute type names can be used in all statements in which dynamic specification of a data type, a class, or an interface is possible. This means that a local type can be prevented from hiding a global type by specifying an absolute type name, and the absolute type names can be used to dynamically access the types, classes, and interfaces of other programs. When a different program is accessed, it is loaded into the current
A data type is uniquely identified by its absolute type name. However, there are different ways of forming a unique path for a type. For example, the specification of a function pool for a type can be omitted in a function module because each function module is unique. For types in a
Even a data type that only exists as a property of a data object and, therefore, does not have a relative type name, has an internal absolute type name (technical type name) that uniquely determines the data type.
Latest notes:
NON_V5_HINTS
ABAP_HINT_END
ABAP_EXAMPLE_VX5
When the methods
PUBLIC SECTION.
METHODS: m1,
m2,
m3 IMPORTING p TYPE any.
ENDCLASS.
CLASS c1 IMPLEMENTATION.
METHOD m1.
DATA struc TYPE spfli.
m3( struc ).
ENDMETHOD.
METHOD m2.
TYPES spfli TYPE spfli.
DATA struc TYPE spfli.
m3( struc ).
ENDMETHOD.
METHOD m3.
DATA type_descr TYPE REF TO cl_abap_typedescr.
type_descr = cl_abap_typedescr=>describe_by_data( p ).
cl_demo_output=>write( type_descr->absolute_name ).
ENDMETHOD.
ENDCLASS.
CLASS exa DEFINITION.
PUBLIC SECTION.
CLASS-METHODS main.
ENDCLASS.
CLASS exa IMPLEMENTATION.
METHOD main.
DATA(ref) = NEW c1( ).
ref->m1( ).
ref->m2( ).
cl_demo_output=>display( ).
ENDMETHOD.
ENDCLASS.>
ABAP_EXAMPLE_END