Ans: Object orientation (OO), or to be more precise, object-oriented programming, is a problem-solving method in which the software solution reflects objects in the real world.
A comprehensive introduction to object orientation as a whole would go far beyond the limits of this introduction to ABAP Objects. This documentation introduces a selection of terms that are used universally in object orientation and also occur in ABAP Objects. In subsequent sections, it goes on to discuss in more detail how these terms are used in ABAP Objects. The end of this section contains a list of further reading, with a selection of titles about object orientation.
Ans: No it is not mandatory to implement all normal interface methods but it is mandatory to implement all Abstract methods.
Ans: Interface is class which contains methods without implementations.
Ans: No, we can not instantiate interface using create object keyword.
Ans: Yes, by using interface concept in SAP ABAp, we can achieve multiple inheritance
Ans: Yes, by using interface concept in SAP ABAP, we can polymorphism
Ans: Abstract class is a class which contains at least one abstract method( Method without implementation), Abstract class contains methods with implementation and without implementation and we cannot create instance for the abstract class .
Ans: Alias is an alias name for the interface method implemented in the class .
Q9. Can We Raise Events In Interface?
Ans: No, you can not raise events in interface, Because there is no Implementation for the methods. We can create events in interfaces .
Ans: Single-ton class is a class which allows to instantiate once only .
Ans: Public attributes can be accessed by class, subclasses and other classes where as Private attributes can be accessed by class itself only.
Ans: A Class is actually a blueprint or a template to create an Object. Whereas an Object is a an actual instance of a Class. For example Employee ia a class, while John is a real employee which is an Object of Employee Class.
Ans: Some examples to implement polymorphism:
Ans: In OOPs terminology, inheritance is a way to form new classes using classes that have already been defined. Inheritance is intended to help reuse existing code with little or no modification. The new classes, known as derived classes, inherit attributes and behavior of the pre-existing classes, which are referred to as base classes.
Ans: Method overloading is in a class have many methods having same name but different parameter called overloading or static polymorphism
Ans: Aggregation is a special form of association. Aggregation is the composition of an object out of a set of parts. For example, a car is an aggregation of engine, tyres, brakes, etc.
Aggregation represents a “Has” relationship like a car has a engine.
Ans: Object oriented programming language allows concepts such as abstraction, modularity, encapsulation, polymorphism and inheritance. Simula is the first object oriented language. Objects are said to be the most important part of object oriented language. Concept revolves around making simulation programs around an object.
Ans: In object-oriented programming, polymorphism (from the Greek meaning “having multiple forms”) is the characteristic of being able to assign a different meaning to a particular symbol or “operator” in different contexts. The simple example is two classes that inherit from a common parent and implement the same virtual method.