/AWS1/IF_FNT=>UPDATEKEYGROUP()¶
About UpdateKeyGroup¶
Updates a key group.
When you update a key group, all the fields are updated with the values provided in the request. You cannot update some fields independent of others. To update a key group:
-
Get the current key group with
GetKeyGrouporGetKeyGroupConfig. -
Locally modify the fields in the key group that you want to update. For example, add or remove public key IDs.
-
Call
UpdateKeyGroupwith the entire key group object, including the fields that you modified and those that you didn't.
Method Signature¶
METHODS /AWS1/IF_FNT~UPDATEKEYGROUP
IMPORTING
!IO_KEYGROUPCONFIG TYPE REF TO /AWS1/CL_FNTKEYGROUPCONFIG OPTIONAL
!IV_ID TYPE /AWS1/FNTSTRING OPTIONAL
!IV_IFMATCH TYPE /AWS1/FNTSTRING OPTIONAL
RETURNING
VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_fntupdatekeygrouprslt
RAISING
/AWS1/CX_FNTINVALIDARGUMENT
/AWS1/CX_FNTINVALIDIFMATCHVRS
/AWS1/CX_FNTKEYGROUPALRDYEX
/AWS1/CX_FNTNOSUCHRESOURCE
/AWS1/CX_FNTPRECONDITIONFAILED
/AWS1/CX_FNTTOOMANYPUBKEYSIN00
/AWS1/CX_FNTCLIENTEXC
/AWS1/CX_FNTSERVEREXC
/AWS1/CX_RT_TECHNICAL_GENERIC
/AWS1/CX_RT_SERVICE_GENERIC.
IMPORTING¶
Required arguments:¶
io_keygroupconfig TYPE REF TO /AWS1/CL_FNTKEYGROUPCONFIG /AWS1/CL_FNTKEYGROUPCONFIG¶
The key group configuration.
iv_id TYPE /AWS1/FNTSTRING /AWS1/FNTSTRING¶
The identifier of the key group that you are updating.
Optional arguments:¶
iv_ifmatch TYPE /AWS1/FNTSTRING /AWS1/FNTSTRING¶
The version of the key group that you are updating. The version is the key group's
ETagvalue.
RETURNING¶
oo_output TYPE REF TO /aws1/cl_fntupdatekeygrouprslt /AWS1/CL_FNTUPDATEKEYGROUPRSLT¶
Domain /AWS1/RT_ACCOUNT_ID Primitive Type NUMC
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->updatekeygroup(
io_keygroupconfig = new /aws1/cl_fntkeygroupconfig(
it_items = VALUE /aws1/cl_fntpublickeyidlist_w=>tt_publickeyidlist(
( new /aws1/cl_fntpublickeyidlist_w( |string| ) )
)
iv_comment = |string|
iv_name = |string|
)
iv_id = |string|
iv_ifmatch = |string|
).
This is an example of reading all possible response values
lo_result = lo_result.
IF lo_result IS NOT INITIAL.
lo_keygroup = lo_result->get_keygroup( ).
IF lo_keygroup IS NOT INITIAL.
lv_string = lo_keygroup->get_id( ).
lv_timestamp = lo_keygroup->get_lastmodifiedtime( ).
lo_keygroupconfig = lo_keygroup->get_keygroupconfig( ).
IF lo_keygroupconfig IS NOT INITIAL.
lv_string = lo_keygroupconfig->get_name( ).
LOOP AT lo_keygroupconfig->get_items( ) into lo_row.
lo_row_1 = lo_row.
IF lo_row_1 IS NOT INITIAL.
lv_string = lo_row_1->get_value( ).
ENDIF.
ENDLOOP.
lv_string = lo_keygroupconfig->get_comment( ).
ENDIF.
ENDIF.
lv_string = lo_result->get_etag( ).
ENDIF.