mirror of
https://github.com/abapGit/abapGit.git
synced 2025-05-01 12:20:51 +08:00
Merge branch 'master' of https://github.com/larshp/abapGit into Make_exceptions_global
This commit is contained in:
commit
50a0702a8a
|
@ -198,7 +198,9 @@ CLASS lcl_http_client IMPLEMENTATION.
|
||||||
|
|
||||||
METHOD send_receive.
|
METHOD send_receive.
|
||||||
|
|
||||||
DATA lv_text TYPE string.
|
DATA: lv_text TYPE string,
|
||||||
|
lv_code TYPE i,
|
||||||
|
lv_message TYPE string.
|
||||||
|
|
||||||
mi_client->send( ).
|
mi_client->send( ).
|
||||||
mi_client->receive(
|
mi_client->receive(
|
||||||
|
@ -207,21 +209,21 @@ CLASS lcl_http_client IMPLEMENTATION.
|
||||||
http_invalid_state = 2
|
http_invalid_state = 2
|
||||||
http_processing_failed = 3
|
http_processing_failed = 3
|
||||||
OTHERS = 4 ).
|
OTHERS = 4 ).
|
||||||
|
|
||||||
IF sy-subrc <> 0.
|
IF sy-subrc <> 0.
|
||||||
CASE sy-subrc.
|
" in case of HTTP_COMMUNICATION_FAILURE
|
||||||
WHEN 1.
|
" make sure:
|
||||||
" make sure:
|
" a) SSL is setup properly in STRUST
|
||||||
" a) SSL is setup properly in STRUST
|
" b) no firewalls
|
||||||
" b) no firewalls
|
" check trace file in transaction SMICM
|
||||||
" check trace file in transaction SMICM
|
|
||||||
lv_text = 'HTTP Communication Failure'. "#EC NOTEXT
|
mi_client->get_last_error(
|
||||||
WHEN 2.
|
IMPORTING
|
||||||
lv_text = 'HTTP Invalid State'. "#EC NOTEXT
|
code = lv_code
|
||||||
WHEN 3.
|
message = lv_message ).
|
||||||
lv_text = 'HTTP Processing failed'. "#EC NOTEXT
|
|
||||||
WHEN OTHERS.
|
lv_text = |HTTP error { lv_code } occured: { lv_message }|.
|
||||||
lv_text = 'Another error occured'. "#EC NOTEXT
|
|
||||||
ENDCASE.
|
|
||||||
zcx_abapgit_exception=>raise( lv_text ).
|
zcx_abapgit_exception=>raise( lv_text ).
|
||||||
ENDIF.
|
ENDIF.
|
||||||
|
|
||||||
|
@ -502,7 +504,7 @@ CLASS lcl_http IMPLEMENTATION.
|
||||||
|
|
||||||
DATA: lv_host TYPE string,
|
DATA: lv_host TYPE string,
|
||||||
lt_list TYPE zif_abapgit_definitions=>ty_icm_sinfo2_tt,
|
lt_list TYPE zif_abapgit_definitions=>ty_icm_sinfo2_tt,
|
||||||
li_exit TYPE ref to lif_exit.
|
li_exit TYPE REF TO lif_exit.
|
||||||
|
|
||||||
CALL FUNCTION 'ICM_GET_INFO2'
|
CALL FUNCTION 'ICM_GET_INFO2'
|
||||||
TABLES
|
TABLES
|
||||||
|
|
|
@ -116,8 +116,7 @@ CLASS lcl_object_iamu IMPLEMENTATION.
|
||||||
object_not_existing = 9
|
object_not_existing = 9
|
||||||
object_invalid = 10
|
object_invalid = 10
|
||||||
error_occured = 11
|
error_occured = 11
|
||||||
content_data_error = 12
|
OTHERS = 12 ).
|
||||||
OTHERS = 13 ).
|
|
||||||
|
|
||||||
IF sy-subrc <> 0.
|
IF sy-subrc <> 0.
|
||||||
zcx_abapgit_exception=>raise( |Error from if_w3_api_mime~set_changeable| ).
|
zcx_abapgit_exception=>raise( |Error from if_w3_api_mime~set_changeable| ).
|
||||||
|
@ -303,8 +302,7 @@ CLASS lcl_object_iamu IMPLEMENTATION.
|
||||||
object_not_existing = 9
|
object_not_existing = 9
|
||||||
object_invalid = 10
|
object_invalid = 10
|
||||||
error_occured = 11
|
error_occured = 11
|
||||||
content_data_error = 12
|
OTHERS = 12 ).
|
||||||
OTHERS = 13 ).
|
|
||||||
|
|
||||||
IF sy-subrc <> 0.
|
IF sy-subrc <> 0.
|
||||||
zcx_abapgit_exception=>raise( |Error from if_w3_api_mime~set_changeable| ).
|
zcx_abapgit_exception=>raise( |Error from if_w3_api_mime~set_changeable| ).
|
||||||
|
|
|
@ -179,6 +179,11 @@ CLASS lcl_object_webi IMPLEMENTATION.
|
||||||
|
|
||||||
METHOD handle_function.
|
METHOD handle_function.
|
||||||
|
|
||||||
|
CONSTANTS: BEGIN OF co_parameter_type,
|
||||||
|
import TYPE vepparamtype VALUE 'I',
|
||||||
|
export TYPE vepparamtype VALUE 'O',
|
||||||
|
END OF co_parameter_type.
|
||||||
|
|
||||||
DATA: li_parameter TYPE REF TO if_ws_md_vif_param,
|
DATA: li_parameter TYPE REF TO if_ws_md_vif_param,
|
||||||
li_soap TYPE REF TO if_ws_md_soap_ext_func,
|
li_soap TYPE REF TO if_ws_md_soap_ext_func,
|
||||||
li_fault TYPE REF TO if_ws_md_vif_fault,
|
li_fault TYPE REF TO if_ws_md_vif_fault,
|
||||||
|
@ -205,16 +210,22 @@ CLASS lcl_object_webi IMPLEMENTATION.
|
||||||
|
|
||||||
LOOP AT is_webi-pvepparameter ASSIGNING <ls_parameter>
|
LOOP AT is_webi-pvepparameter ASSIGNING <ls_parameter>
|
||||||
WHERE function = <ls_function>-function.
|
WHERE function = <ls_function>-function.
|
||||||
|
|
||||||
CASE <ls_parameter>-vepparamtype.
|
CASE <ls_parameter>-vepparamtype.
|
||||||
WHEN 'I'.
|
WHEN co_parameter_type-import.
|
||||||
|
|
||||||
li_parameter = li_function->create_incoming_parameter(
|
li_parameter = li_function->create_incoming_parameter(
|
||||||
<ls_parameter>-vepparam ).
|
<ls_parameter>-vepparam ).
|
||||||
WHEN 'E'.
|
|
||||||
|
WHEN co_parameter_type-export.
|
||||||
|
|
||||||
li_parameter = li_function->create_outgoing_parameter(
|
li_parameter = li_function->create_outgoing_parameter(
|
||||||
<ls_parameter>-vepparam ).
|
<ls_parameter>-vepparam ).
|
||||||
|
|
||||||
WHEN OTHERS.
|
WHEN OTHERS.
|
||||||
ASSERT 0 = 1.
|
ASSERT 0 = 1.
|
||||||
ENDCASE.
|
ENDCASE.
|
||||||
|
|
||||||
li_parameter->set_name_mapped_to( <ls_parameter>-mappedname ).
|
li_parameter->set_name_mapped_to( <ls_parameter>-mappedname ).
|
||||||
li_parameter->set_is_exposed( <ls_parameter>-is_exposed ).
|
li_parameter->set_is_exposed( <ls_parameter>-is_exposed ).
|
||||||
li_parameter->set_is_optional( <ls_parameter>-is_optional ).
|
li_parameter->set_is_optional( <ls_parameter>-is_optional ).
|
||||||
|
|
Loading…
Reference in New Issue
Block a user