Message Class in SAP ABAP

18 Introduction To issue a message or warning or error or any kind of information in ABAP, either we have to hard code that message or maintain it in text symbols. What if the same message is required somewhere else like in any other program or class, again hard coding it or maintaining in text […]

SAP ABAP Unit Testing Class

49 Introduction ABAP unit testing is a methodology for software development. Whenever we create a class, it is mandatory to create its test class to check the behavior of our code if it is working exactly as it was expected.  While developing any object, it helps the developer to cover all possible scenarios. With ABAP […]

Exception Class in SAP ABAP

345 Introduction To understand an exception class, we need to understand what is an exception and when it is raised. When we execute any program, some discrepancies can occur due to which a normal flow of execution gets interrupted and the behavior will not be the same as it was expected. That discrepancy is like […]

Local Classes in SAP ABAP

44 Introduction One of the flavors of ABAP classes (Global Classes) we have already discussed in the last article. Another flavor of ABAP class are Local Classes. The only difference between a local class & global class is visibility & accessibility. A local class can be accessed within that program only in which it is […]

Super Class in SAP ABAP

45 Introduction: One of the three pillars of OOABAP uses this concept of Super class to achieve ‘Inheritance’. Super class allows us to extend that class by creating a subclass of it. This subclass will have all the properties of a super class, plus it can have additional properties as well. Definition: A class which […]

Global Class in SAP ABAP

47 Introduction: From the reference of an article: SAP ABAP Classes we have discussed the flavors of ABAP Classes & we came to know that ABAP classes are available in two flavors, one of which is Global Class. The visibility section of the global class is always public, meaning all the ABAP programs in an […]

Singleton Class in ABAP

333 Introduction: Sometimes there is a need to instantiate an object at a time, that means only one instance is required at one point of time. This is a very common requirement while designing an application. To achieve such a scenario, there is one concept of ‘Singleton Pattern’ or ‘Singleton Class’ in OOABAP. This was […]

Abstract Class in SAP ABAP

237 Introduction: In simpler words, a class can be called as an abstract class, if it would contain at least one abstract method. Now, the question comes, what is an abstract method? An abstract method is a method which does not have an implementation. Now, a question will come to your mind, if a method […]

Final Class in SAP ABAP

172 Introduction: A class is said to be a ‘Final Class’ when it is no longer available for inheritance. Therefore, we won’t be able to inherit the properties or behavior of a final class. A final class does not have a subclass. However, if you don’t want to make a whole class final, and if […]

Friend Class in SAP ABAP

320 Introduction: In the previous article, we have discussed the classes, its components and the visibility of components. As per the visibility section, only public methods or attributes of a class are allowed to be used by some other classes. Now, what if we want to access non-public (protected or private) components (methods or attributes) […]

Translate »