*&---------------------------------------------------------------------*
*& Include Z17_011_CLASS *
*&---------------------------------------------------------------------*
* Definition part
******************************************
CLASS lcl_airplane DEFINITION.
*------------------------------
* Public section
*------------------------------
PUBLIC SECTION.
TYPES: t_name(25) TYPE c.
METHODS:
constructor,
set_attributes IMPORTING p_name TYPE t_name
p_planetype TYPE saplane-planetype,
display_attributes,
display_n_o_airplanes.
*------------------------------
* Private section
*------------------------------
PRIVATE SECTION.
* Private attributes
DATA: name(25) TYPE c,
planetype TYPE saplane-planetype.
* Private static attribute
CLASS-DATA n_o_airplanes TYPE i.
ENDCLASS.
******************************************
* Implementation part
******************************************
CLASS lcl_airplane IMPLEMENTATION.
METHOD constructor.
* Counts number of instances
n_o_airplanes = n_o_airplanes + 1.
ENDMETHOD.
METHOD set_attributes.
name = p_name.
planetype = p_planetype.
ENDMETHOD.
METHOD display_attributes.
WRITE:/ 'Name:', name, 'Planetype:', planetype.
ENDMETHOD.
METHOD display_n_o_airplanes.
WRITE: / 'No. planes:', n_o_airplanes.
ENDMETHOD.
ENDCLASS.
*& Include Z17_011_CLASS *
*&---------------------------------------------------------------------*
* Definition part
******************************************
CLASS lcl_airplane DEFINITION.
*------------------------------
* Public section
*------------------------------
PUBLIC SECTION.
TYPES: t_name(25) TYPE c.
METHODS:
constructor,
set_attributes IMPORTING p_name TYPE t_name
p_planetype TYPE saplane-planetype,
display_attributes,
display_n_o_airplanes.
*------------------------------
* Private section
*------------------------------
PRIVATE SECTION.
* Private attributes
DATA: name(25) TYPE c,
planetype TYPE saplane-planetype.
* Private static attribute
CLASS-DATA n_o_airplanes TYPE i.
ENDCLASS.
******************************************
* Implementation part
******************************************
CLASS lcl_airplane IMPLEMENTATION.
METHOD constructor.
* Counts number of instances
n_o_airplanes = n_o_airplanes + 1.
ENDMETHOD.
METHOD set_attributes.
name = p_name.
planetype = p_planetype.
ENDMETHOD.
METHOD display_attributes.
WRITE:/ 'Name:', name, 'Planetype:', planetype.
ENDMETHOD.
METHOD display_n_o_airplanes.
WRITE: / 'No. planes:', n_o_airplanes.
ENDMETHOD.
ENDCLASS.
댓글 0
번호 | 제목 | 글쓴이 | 날짜 | 조회 수 |
---|---|---|---|---|
111 | REPORT Z17_000. | sapjoy | 2007.02.22 | 2422 |
110 | REPORT Z17_022 | sapjoy | 2007.02.22 | 2317 |
109 | REPORT Z17_021 . | sapjoy | 2007.02.21 | 2401 |
108 | REPORT Z17_019 [1] | sapjoy | 2007.02.15 | 2757 |
107 | REPORT Z17_017 . | sapjoy | 2007.02.15 | 2185 |
106 | REPORT Z17_016 . | sapjoy | 2007.02.14 | 2166 |
105 | REPORT Z17_015 | sapjoy | 2007.02.13 | 2287 |
104 | REPORT Z17_014. [1] | sapjoy | 2007.02.13 | 2510 |
103 | REPORT Z17_012 | sapjoy | 2007.02.13 | 2309 |
» | INCLUDE Z17_011_CLASS | sapjoy | 2007.02.12 | 2495 |
101 | REPORT Z17_011 | sapjoy | 2007.02.12 | 2289 |
100 | REPORT Z017_007 [3] | sapjoy | 2007.02.12 | 2362 |
99 | REPORT Z17_006 | sapjoy | 2007.02.12 | 2215 |
98 | REPORT Z17_005 | sapjoy | 2007.02.12 | 2178 |
97 | REPORT Z17_004. | sapjoy | 2007.02.12 | 2518 |
96 | REPORT Z17_003 | sapjoy | 2007.02.09 | 2352 |
95 | REPORT Z17_002 | sapjoy | 2007.02.08 | 2144 |
94 | REPORT Z17_001. | sapjoy | 2007.02.07 | 2153 |
93 | REPORT Z15_039 | sapjoy | 2007.02.06 | 2317 |
92 | REPORT Z15_038 | sapjoy | 2007.02.06 | 2181 |