/AWS1/IF_MCI=>GETCONNECTION()¶
About GetConnection¶
Describes the current state of a Connection resource as specified by the identifier.
Method Signature¶
METHODS /AWS1/IF_MCI~GETCONNECTION
IMPORTING
!IV_IDENTIFIER TYPE /AWS1/MCICONNECTIONID OPTIONAL
RETURNING
VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_mcigetconnresponse
RAISING
/AWS1/CX_MCIACCESSDENIEDEX
/AWS1/CX_MCIINTERCNCTCLIENTEX
/AWS1/CX_MCIINTERCNCTSERVEREX
/AWS1/CX_MCIINTERCNCTVLDTNEX
/AWS1/CX_MCIRESOURCENOTFOUNDEX
/AWS1/CX_MCISERVICEQUOTAEXCDEX
/AWS1/CX_MCITHROTTLINGEX
/AWS1/CX_MCICLIENTEXC
/AWS1/CX_MCISERVEREXC
/AWS1/CX_RT_TECHNICAL_GENERIC
/AWS1/CX_RT_SERVICE_GENERIC.
IMPORTING¶
Required arguments:¶
iv_identifier TYPE /AWS1/MCICONNECTIONID /AWS1/MCICONNECTIONID¶
The identifier of the requested Connection
RETURNING¶
oo_output TYPE REF TO /aws1/cl_mcigetconnresponse /AWS1/CL_MCIGETCONNRESPONSE¶
Examples¶
Syntax Example¶
This is an example of the syntax for calling the method. It includes every possible argument and initializes every possible value. The data provided is not necessarily semantically accurate (for example the value "string" may be provided for something that is intended to be an instance ID, or in some cases two arguments may be mutually exclusive). The syntax shows the ABAP syntax for creating the various data structures.
DATA(lo_result) = lo_client->getconnection( |string| ).
This is an example of reading all possible response values
lo_result = lo_result.
IF lo_result IS NOT INITIAL.
lo_connection = lo_result->get_connection( ).
IF lo_connection IS NOT INITIAL.
lv_connectionid = lo_connection->get_id( ).
lv_amazonresourcename = lo_connection->get_arn( ).
lv_connectiondescription = lo_connection->get_description( ).
lv_connectionbandwidth = lo_connection->get_bandwidth( ).
lo_attachpoint = lo_connection->get_attachpoint( ).
IF lo_attachpoint IS NOT INITIAL.
lv_directconnectgatewayatt = lo_attachpoint->get_directconnectgateway( ).
lv_amazonresourcename = lo_attachpoint->get_arn( ).
ENDIF.
lv_environmentid = lo_connection->get_environmentid( ).
lo_provider = lo_connection->get_provider( ).
IF lo_provider IS NOT INITIAL.
lv_cloudserviceprovider = lo_provider->get_cloudserviceprovider( ).
lv_lastmileprovider = lo_provider->get_lastmileprovider( ).
ENDIF.
lv_location = lo_connection->get_location( ).
lv_producttype = lo_connection->get_type( ).
lv_connectionstate = lo_connection->get_state( ).
lv_connectionsharedid = lo_connection->get_sharedid( ).
lv_billingtier = lo_connection->get_billingtier( ).
lv_owneraccountid = lo_connection->get_owneraccount( ).
lv_activationkey = lo_connection->get_activationkey( ).
LOOP AT lo_connection->get_tags( ) into ls_row.
lv_key = ls_row-key.
lo_value = ls_row-value.
IF lo_value IS NOT INITIAL.
lv_tagvalue = lo_value->get_value( ).
ENDIF.
ENDLOOP.
ENDIF.
ENDIF.
Get connection¶
Get connection
DATA(lo_result) = lo_client->getconnection( |mcc-abc12345| ).