动态方法调用区分大小写 [英] Dynamic method call is case-sensitive
问题描述
最小工作示例:
CLASS lcl_some_class DEFINITION. ""// <-- this is obviously lower case
PUBLIC SECTION.
CLASS-METHODS some_static_method. ""// <-- this is obviously lower case
PROTECTED SECTION.
PRIVATE SECTION.
ENDCLASS.
CLASS lcl_some_class IMPLEMENTATION.
METHOD some_static_method.
" nothing
ENDMETHOD.
ENDCLASS.
END-OF-SELECTION.
DATA: lc_class_name_upper TYPE string VALUE 'LCL_SOME_CLASS',
lc_class_name_lower TYPE string VALUE 'lcl_some_class',
lc_method_name_upper TYPE string VALUE 'SOME_STATIC_METHOD',
lc_method_name_lower TYPE string VALUE 'some_static_method'.
CALL METHOD LCL_SOME_CLASS=>SOME_STATIC_METHOD. ""ok
CALL METHOD (lc_class_name_upper)=>(lc_method_name_upper). ""ok
CALL METHOD lcl_some_class=>SOME_STATIC_METHOD. ""ok
CALL METHOD (lc_class_name_lower)=>(lc_method_name_upper). ""failure
CALL METHOD LCL_SOME_CLASS=>some_static_method. ""ok
CALL METHOD (lc_class_name_upper)=>(lc_method_name_lower). ""failure
CALL METHOD lCl_SoMe_ClAsS=>sOmE_sTaTiC_mEtHoD. ""ok
我希望带有注释"failure"的行出现在行为与上面的相应行完全相同:区分大小写.但是相反,它们失败并显示以下消息之一:
I expected the lines with comment "failure" to behave exactly like the corresponding lines above: To be case-insentive. But instead they fail with one of the following messages:
CX_SY_DYN_CALL_ILLEGAL_CLASS/DYN_CALL_METH_CLASS_NOT_FOUND
CX_SY_DYN_CALL_ILLEGAL_CLASS / DYN_CALL_METH_CLASS_NOT_FOUND
en:在动态方法调用期间找不到该类.
en: The class could not be found during the dynamic method call.
de:Die Klasse beim dynamischen Methodenaufruf konnte nicht gefunden werden.
de: Die Klasse beim dynamischen Methodenaufruf konnte nicht gefunden werden.
CX_SY_DYN_CALL_ILLEGAL_METHOD/DYN_CALL_METH_NOT_FOUND
CX_SY_DYN_CALL_ILLEGAL_METHOD / DYN_CALL_METH_NOT_FOUND
en:在动态调用期间找不到该方法.
en: The method could not be found during the dynamic call.
de:Die Methode konnte beim dynamischen Aufruf nicht gefunden werden.
de: Die Methode konnte beim dynamischen Aufruf nicht gefunden werden.
是否有办法使动态呼叫大小写敏感( )(明显的将字符串转换为大写字母除外)?
Is there a way to make the dynamic call case-insensitive (except for the obvious converting the strings to upper case)?