Object Orientation Main Features
- Class
Defines the abstract characteristics of a thing (object), including the thing’s characteristics (its attributes, fields or properties) and the thing’s behaviors (the things it can do, or methods, operations or features).
- Object
A pattern (exemplar) of a class.
- Instance
One can have an instance of a class or a particular object. The instance is the actual object created at runtime.
- Inheritance
‘Subclasses’ are more specialized versions of a class, which inherit attributes and behaviors from their parent classes, and can introduce their own.
- Encapsulation
Encapsulation conceals the functional details of a class from objects that send messages to it.
- Abstraction
Abstraction is simplifying complex reality by modelling classes appropriate to the problem, and working at the most appropriate level of inheritance for a given aspect of the problem.
- Polymorphism
Polymorphism allows the programmer to treat derived class members just like their parent class’ members. More precisely, Polymorphism in object-oriented programming is the ability of objects belonging to different data types to respond to method calls of methods of the same name, each one according to an appropriate type-specific behavior. One method, or an operator such as +, -, or *, can be abstractly applied in many different situations.
- Overriding
Overriding allows to change the functionality of the inherited methods. This is also known as the redefinition. Follow this blog - ABAP Objects: Overriding(Redefinition) for more information (Note: outside SDN link).
Object Orientation Advanced Features
- Narrowing Cast (Upcasting)
When we assign the instance of the Subclass back to the instance of the Superclass, than it is called the “Narrow Casting”, because we are switching from a “More Specific view of an object” to “less specific view”. Visit this blog - ABAP Objects: Narrowing Cast (Upcasting) for more information (Note: outside SDN link)
- Widening Cast (Downcasting)
When we assign the instance of the Superclass to the Subclass, than it is called the Widening Cast, because we are moving to the “More Specific View” from the “Less specific view”. Due to this reason it is also called the “Down Casting”. Visit this blog - ABAP Objects: Widening Cast (Downcasting) for more information (Note: outside SDN link).
February 7, 2009 No Comments
SAP ABAP Object Orientation Overview
SAP ABAP Object Orientation Overview
Object-oriented programming (OOP) is a programming paradigm that uses “objects” and their interactions to design applications and computer programs. Programming techniques may include features such as encapsulation, modularity, polymorphism, and inheritance. It was not commonly used in mainstream software application development until the early 1990s. Many modern programming languages now support OOP.
February 7, 2009 No Comments
SAP ABAP Objects
ABAP Objects is a Object-Oriented extension to the ABAP Programming language and was Introduced on SAP Basis Release 4.5.
“ABAP Objects is indicated for who wants to guarantee agility during the development, minimize the efforts during the modifications, enhance existing applications and create complex applications using a simple way…”
The principal features of ABAP Objects are:
* Encapsulation
* Instantiation
* Inheritance
* Interfacing
* Events
…The ABAP runtime support for both procedural and ABAP Objects programming models enables you to use ABAP objects in any program. I.e. in executable programs, module pools, Function pools. This enables you to use new techniques based on ABAP Objects, such as new interfaces, without the need to completely rewrite your existing code.
In OO Programming the only structuring units are classes. Instead of working with global data, you work with objects, which are instances of classes. These objects encapsulate the state and behavior of self-contained parts of the application.
February 7, 2009 No Comments
Hello world!
January 20, 2009 1 Comment
