SAP---ABAP

Saturday, November 24, 2007



Working on Polymorphism >>>Next>>>


POLYMORPHISM:-


Polymorphism is a characteristic of being able to assign a different behavior or value in a subclass, to something that was declared in a parent class. For example, a method can be declared in a parent class, but each subclass can have a different implementation of that method. This allows each subclass to differ, without the parent class being explicitly aware that a difference exists.


CLAUSES REGARDING POLYMORPHISM:-


1.Allows one interface to be used for a general class of actions.

2.When objects from different classes react differently to the same procedural call.

3.User can work with different classes in a similar way, regardless of their implementation.

4.Allows improved code organization and readability as well as creation of “extensible” programs.

5.Although the form of address is always the same, the implementation of the method is specific to a particular class.


Go to SE24 T-code.






Press create button.






Press Save button



Provide methods.







Select the first method then provide the parameters for this method.







Go back to the methods then double click on the method name.

Then provide the logic.


>>>Next>>>



No comments: