本帖最后由 yangjulei 于 2014-4-17 13:14 编辑
CLASS - DEFERRED
Syntax
CLASS class DEFINITION DEFERRED [PUBLIC].
Effect
This variant of the statement CLASS is used to make the class class known, regardless of the location of the actual definition of the class in the program. It does not introduce a declaration part and must not be ended using ENDCLASS.
这个的意思就是说,
你在定义class的时候,
data xxx type ref to class_a.
class a的定义在这句语句的下面,如果不提前声明,就会报错,用了上面这句就ok了。
相当于先告诉系统,这个在后面定义的意思.
----------------------------------------------
Addition 2... LOAD
EffectThe variant with the LOAD addition loads a global class class from the Class Library.
官方的帮助是说,当使用一个class的method编译失败时,可以用上。
https://help.sap.com/abapdocu_70/en/ABAPCLASS_DEFERRED.htm#&ABAP_ADDITION_2@2@
大家共同学习吧。
|