Real Life Examples of OOPs in SAP ABAP
Abstraction:
- Real-life example: – A car company shows the accelerator, clutch, and brake to the driver which is relevant, they do not show the mechanic of the brake which is non-essential for the driver.
Encapsulation:
- Real-life example: – When a kid goes to school, they put books, pens, pencils, lunchbox, etc. in a single bag. So, here bag acts as an encapsulation.
Polymorphism:
- Real-life example: – A student named Kanu acts as a student in school. When he goes home, he acts as a son. So here, the object is the same i.e. Kanu but his behavior changes according to the places.
Inheritance:
- Real-life example: – Let’s consider a father and a child. Father’s name is Shekhar and son’s name is Kanu. Shekhar has brown skin, black hair, and grey eyes. Kanu also has grey eyes. So here, Kanu inherited the property of grey eyes from his father. Kanu acts as a derived class and Shekhar acts as a base class.
SAP ABAP | Object Orientation
The SAP ecosystem creates applications with the programming language SAP ABAP (Advanced Business Application Programming) t is created by SAP which is a domain-specific language, it is the 4th generation programming language. It is also called ABAP/4(Fourth Generation Language” or 4GL). mainly for enterprise resource planning (ERP) systems. The introduction of Object Orientation in ABAP increased the language’s capabilities and brought it in line with modern programming paradigms.