Skip to content

/AWS1/IF_MGN=>LISTNETWORKMIGRMAPPERSEGS()

About ListNetworkMigrationMapperSegments

Lists mapper segments, which represent logical groupings of network resources to be migrated together.

Method Signature

METHODS /AWS1/IF_MGN~LISTNETWORKMIGRMAPPERSEGS
  IMPORTING
    !IV_NETWORKMIGRATIONEXECID TYPE /AWS1/MGNNETWORKMIGREXECID OPTIONAL
    !IV_NETWORKMIGRATIONDEFNID TYPE /AWS1/MGNNETWORKMIGRDEFNID OPTIONAL
    !IO_FILTERS TYPE REF TO /AWS1/CL_MGNLSTNETMIGMAPSEGFLT OPTIONAL
    !IV_MAXRESULTS TYPE /AWS1/MGNMAXRESULTSTYPE OPTIONAL
    !IV_NEXTTOKEN TYPE /AWS1/MGNPAGINATIONTOKEN OPTIONAL
  RETURNING
    VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_mgnlstnetmigmapsegrsp
  RAISING
    /AWS1/CX_MGNACCESSDENIEDEX
    /AWS1/CX_MGNRESOURCENOTFOUNDEX
    /AWS1/CX_MGNTHROTTLINGEX
    /AWS1/CX_MGNVALIDATIONEX
    /AWS1/CX_MGNCLIENTEXC
    /AWS1/CX_MGNSERVEREXC
    /AWS1/CX_RT_TECHNICAL_GENERIC
    /AWS1/CX_RT_SERVICE_GENERIC.

IMPORTING

Required arguments:

iv_networkmigrationexecid TYPE /AWS1/MGNNETWORKMIGREXECID /AWS1/MGNNETWORKMIGREXECID

The unique identifier of the network migration execution.

iv_networkmigrationdefnid TYPE /AWS1/MGNNETWORKMIGRDEFNID /AWS1/MGNNETWORKMIGRDEFNID

The unique identifier of the network migration definition.

Optional arguments:

io_filters TYPE REF TO /AWS1/CL_MGNLSTNETMIGMAPSEGFLT /AWS1/CL_MGNLSTNETMIGMAPSEGFLT

Filters to apply when listing segments.

iv_maxresults TYPE /AWS1/MGNMAXRESULTSTYPE /AWS1/MGNMAXRESULTSTYPE

The maximum number of results to return in a single call.

iv_nexttoken TYPE /AWS1/MGNPAGINATIONTOKEN /AWS1/MGNPAGINATIONTOKEN

The token for the next page of results.

RETURNING

oo_output TYPE REF TO /aws1/cl_mgnlstnetmigmapsegrsp /AWS1/CL_MGNLSTNETMIGMAPSEGRSP

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->listnetworkmigrmappersegs(
  io_filters = new /aws1/cl_mgnlstnetmigmapsegflt(
    it_segmentids = VALUE /aws1/cl_mgnlstnetmigmapsegi00=>tt_listnetmigrmapprsegsidsfilt(
      ( new /aws1/cl_mgnlstnetmigmapsegi00( |string| ) )
    )
  )
  iv_maxresults = 123
  iv_networkmigrationdefnid = |string|
  iv_networkmigrationexecid = |string|
  iv_nexttoken = |string|
).

This is an example of reading all possible response values

lo_result = lo_result.
IF lo_result IS NOT INITIAL.
  LOOP AT lo_result->get_items( ) into lo_row.
    lo_row_1 = lo_row.
    IF lo_row_1 IS NOT INITIAL.
      lv_networkmigrationjobid = lo_row_1->get_jobid( ).
      lv_networkmigrationexecuti = lo_row_1->get_networkmigrationexecid( ).
      lv_networkmigrationdefinit = lo_row_1->get_networkmigrationdefnid( ).
      lv_segmentid = lo_row_1->get_segmentid( ).
      lv_networkmigrationmappers = lo_row_1->get_segmenttype( ).
      lv_segmentname = lo_row_1->get_name( ).
      lv_segmentdescription = lo_row_1->get_description( ).
      lv_logicalid = lo_row_1->get_logicalid( ).
      lo_checksum = lo_row_1->get_checksum( ).
      IF lo_checksum IS NOT INITIAL.
        lv_encryptionalgorithm = lo_checksum->get_encryptionalgorithm( ).
        lv_hash = lo_checksum->get_hash( ).
      ENDIF.
      lo_s3configuration = lo_row_1->get_outputs3configuration( ).
      IF lo_s3configuration IS NOT INITIAL.
        lv_s3bucketname = lo_s3configuration->get_s3bucket( ).
        lv_accountid = lo_s3configuration->get_s3bucketowner( ).
        lv_s3keyname = lo_s3configuration->get_s3key( ).
      ENDIF.
      lv_timestamp = lo_row_1->get_createdat( ).
      lv_timestamp = lo_row_1->get_updatedat( ).
      LOOP AT lo_row_1->get_scopetags( ) into ls_row_2.
        lv_key = ls_row_2-key.
        lo_value = ls_row_2-value.
        IF lo_value IS NOT INITIAL.
          lv_scopetagvalue = lo_value->get_value( ).
        ENDIF.
      ENDLOOP.
      lv_accountid = lo_row_1->get_targetaccount( ).
      LOOP AT lo_row_1->get_referencedsegments( ) into lo_row_3.
        lo_row_4 = lo_row_3.
        IF lo_row_4 IS NOT INITIAL.
          lv_segmentid = lo_row_4->get_value( ).
        ENDIF.
      ENDLOOP.
    ENDIF.
  ENDLOOP.
  lv_paginationtoken = lo_result->get_nexttoken( ).
ENDIF.

Sample ListNetworkMigrationMapperSegments call

Sample ListNetworkMigrationMapperSegments call

DATA(lo_result) = lo_client->listnetworkmigrmappersegs(
  iv_networkmigrationdefnid = |nmd-01234567891234567|
  iv_networkmigrationexecid = |01234567-abcd-abcd-abcd-0123456789ab|
).