class q1 DEFINITION.
PUBLIC SECTION.
data: a TYPE i VALUE 10. <-------me->a
METHODs:constructor.
ENDCLASS.
CLASS q1 IMPLEMENTATION.
METHOD: constructor.
data: a TYPE i value 20.
write:/ ' The Value of class is', me->a ,
/ ' The value of class is ',a .
ENDMETHOD.
ENDCLASS.
START-OF-SELECTION.
data obj TYPE REF TO q1.
CREATE OBJECT obj.
PUBLIC SECTION.
data: a TYPE i VALUE 10. <-------me->a
METHODs:constructor.
ENDCLASS.
CLASS q1 IMPLEMENTATION.
METHOD: constructor.
data: a TYPE i value 20.
write:/ ' The Value of class is', me->a ,
/ ' The value of class is ',a .
ENDMETHOD.
ENDCLASS.
START-OF-SELECTION.
data obj TYPE REF TO q1.
CREATE OBJECT obj.
No comments:
Post a Comment