This is my singleton class in ABAP: CLASSzcl_jerry_singletonDEFINITIONPUBLICFINALCREATE PRIVATE.PUBLIC SECTION.INTERFACESif_serializable_object.CLASS-METHODSclass_constructor.CLASS-METHODSget_instanceRETURNINGVALUE(ro_instance)TYPE REF TOzcl_jerry_singleton.PROTECTED SECTION.PRIVATE SECTION.CLASS-DATAso_instanc...
Labels in this area - SAP 1 A Dynamic Memory Allocation Tool 1 A Unit Test for function Module 1 ABAP 22 ABAP 7.4 5 ABAP API 1 ABAP auf HANA 1 abap cds 2 ABAP CDS VIEW 2 ABAP CDS Views 14 ABAP Class 1 ABAP Cloud 4 ABAP development 7 ABAP Environment & RAP ...
How do we use singleton in OO ABAP, Can someone please give a perfect example. That would be great help Reply 1 ACCEPTED SOLUTION FredericGirod Active Contributor 2020 Feb 25 6:22 AM 11 Kudos 13,237 SAP Managed Tags: ABAP Development Singleton is basically, a static instance...
How to implement Singleton design Pattern in ABAP? We can use the CLASS-DATA(static data) to save the created instance within the class and check with that instance, if application asks for a new instance. We will look at this example. UML diagrm for the example: Code Snippet: *&---*...