GET_MEMORY_SIZE_OF_OBJECT SAP Method Calculate memory size of a dynamically created object









Below is documentation, parameters and attributes of ABAP Method GET_MEMORY_SIZE_OF_OBJECT within SAP class CL_ABAP_MEMORY_UTILITIES. There is also a number of example ABAP code snipts to help you use the functionality of this method.

This method is available within SAP systems depending on your version and release level, you can view further information by entering the class name CL_ABAP_MEMORY_UTILITIES into the relevant SAP transactions such as SE24 or SE80, and then selecting the method you are interested in.


Method Type - Static

This is a Static Method so you can call it directly

The following technical details of method GET_MEMORY_SIZE_OF_OBJECT can also be found below:

  • Importing parameters
  • Exporting parameters
  • Changing parameters
  • Returning parameters
  • Exceptions
  • Coding Examples


Parameters of Method GET_MEMORY_SIZE_OF_OBJECT

.

NameTypeData TypeDescriptionDefault Value
IGNORE_STRING_SHARINGImportingTYPE
C
Flag to Indicate Whether String Sharing Is Ignored
IGNORE_TABLE_SHARINGImportingTYPE
C
Flag to Indicate Whether Table Sharing Is Ignored
OBJECTImportingTYPE
ANY
Object to be calculated
BOUND_SIZE_ALLOCExportingTYPE
ABAP_MSIZE
Size of Bound and Allocated Memory
BOUND_SIZE_USEDExportingTYPE
ABAP_MSIZE
Size of Bound and Used Memory
IS_IN_SHARED_MEMORYExportingTYPE
C
Flag to Indicate Whether OBJECT Is in Shared Memory.
IS_PART_OF_NON_TRIVIAL_SZKExportingTYPE
C
Strongly Connected Component (SCC) of Object
LOW_MEMExportingTYPE
C
Flag Whether Only bound_size_* are filled (Memory Shortage)
REFERENCED_SIZE_ALLOCExportingTYPE
ABAP_MSIZE
Size of Referenced and Allocated Memory
REFERENCED_SIZE_USEDExportingTYPE
ABAP_MSIZE
Size of Referenced and Used Memory
SIZEOF_ALLOCExportingTYPE
ABAP_MSIZE
Size of the Allocated Repository without Children
SIZEOF_USEDExportingTYPE
ABAP_MSIZE
Size of the Repository Used without Children
SZK_SIZE_ALLOCExportingTYPE
ABAP_MSIZE
Size of Allocated Memory of SCC
SZK_SIZE_USEDExportingTYPE
ABAP_MSIZE
Size of Used Memory of SCC



Exceptions of Method GET_MEMORY_SIZE_OF_OBJECT

This method does not have any exceptions

Example ABAP coding


DATA: lv_BOUND_SIZE_ALLOC TYPE ABAP_MSIZE,
lv_BOUND_SIZE_USED TYPE ABAP_MSIZE,
lv_IGNORE_STRING_SHARING TYPE C,
lv_IGNORE_TABLE_SHARING TYPE C,
lv_IS_IN_SHARED_MEMORY TYPE C,
lv_IS_PART_OF_NON_TRIVIAL_SZK TYPE C,
lv_LOW_MEM TYPE C,
lv_OBJECT TYPE ANY,
lv_REFERENCED_SIZE_ALLOC TYPE ABAP_MSIZE,
lv_REFERENCED_SIZE_USED TYPE ABAP_MSIZE,
lv_SIZEOF_ALLOC TYPE ABAP_MSIZE,
lv_SIZEOF_USED TYPE ABAP_MSIZE,
lv_SZK_SIZE_ALLOC TYPE ABAP_MSIZE,
lv_SZK_SIZE_USED TYPE ABAP_MSIZE,
lv_other TYPE c.

CALL METHOD CL_ABAP_MEMORY_UTILITIES=>GET_MEMORY_SIZE_OF_OBJECT(
EXPORTING
IGNORE_STRING_SHARING = lv_IGNORE_STRING_SHARING
IGNORE_TABLE_SHARING = lv_IGNORE_TABLE_SHARING
OBJECT = lv_OBJECT
IMPORTING
BOUND_SIZE_ALLOC = lv_BOUND_SIZE_ALLOC
BOUND_SIZE_USED = lv_BOUND_SIZE_USED
IS_IN_SHARED_MEMORY = lv_IS_IN_SHARED_MEMORY
IS_PART_OF_NON_TRIVIAL_SZK = lv_IS_PART_OF_NON_TRIVIAL_SZK
LOW_MEM = lv_LOW_MEM
REFERENCED_SIZE_ALLOC = lv_REFERENCED_SIZE_ALLOC
REFERENCED_SIZE_USED = lv_REFERENCED_SIZE_USED
SIZEOF_ALLOC = lv_SIZEOF_ALLOC
SIZEOF_USED = lv_SIZEOF_USED
SZK_SIZE_ALLOC = lv_SZK_SIZE_ALLOC
SZK_SIZE_USED = lv_SZK_SIZE_USED ).

Links to Related Class(s)

CL_ABAP_...
Full list of available SAP object classes

Search for further information about these or an SAP related objects



Comments on this SAP object

What made you want to lookup this SAP object? Please tell us what you were looking for and anything you would like to be included on this page!