/AWS1/IF_SMC=>CREATEROTATION()¶
About CreateRotation¶
Creates a rotation in an on-call schedule.
Method Signature¶
METHODS /AWS1/IF_SMC~CREATEROTATION
IMPORTING
!IV_NAME TYPE /AWS1/SMCROTATIONNAME OPTIONAL
!IT_CONTACTIDS TYPE /AWS1/CL_SMCROTATIONCONTACTS00=>TT_ROTATIONCONTACTSARNLIST OPTIONAL
!IV_STARTTIME TYPE /AWS1/SMCDATETIME OPTIONAL
!IV_TIMEZONEID TYPE /AWS1/SMCTIMEZONEID OPTIONAL
!IO_RECURRENCE TYPE REF TO /AWS1/CL_SMCRECURRENCESETTINGS OPTIONAL
!IT_TAGS TYPE /AWS1/CL_SMCTAG=>TT_TAGSLIST OPTIONAL
!IV_IDEMPOTENCYTOKEN TYPE /AWS1/SMCIDEMPOTENCYTOKEN OPTIONAL
RETURNING
VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_smccreaterotationrslt
RAISING
/AWS1/CX_SMCACCESSDENIEDEX
/AWS1/CX_SMCINTERNALSERVEREX
/AWS1/CX_SMCRESOURCENOTFOUNDEX
/AWS1/CX_SMCSERVICEQUOTAEXCDEX
/AWS1/CX_SMCTHROTTLINGEX
/AWS1/CX_SMCVALIDATIONEX
/AWS1/CX_SMCCLIENTEXC
/AWS1/CX_SMCSERVEREXC
/AWS1/CX_RT_TECHNICAL_GENERIC
/AWS1/CX_RT_SERVICE_GENERIC.
IMPORTING¶
Required arguments:¶
iv_name TYPE /AWS1/SMCROTATIONNAME /AWS1/SMCROTATIONNAME¶
The name of the rotation.
it_contactids TYPE /AWS1/CL_SMCROTATIONCONTACTS00=>TT_ROTATIONCONTACTSARNLIST TT_ROTATIONCONTACTSARNLIST¶
The Amazon Resource Names (ARNs) of the contacts to add to the rotation.
Only the
PERSONALcontact type is supported. The contact typesESCALATIONandONCALL_SCHEDULEare not supported for this operation.The order that you list the contacts in is their shift order in the rotation schedule. To change the order of the contact's shifts, use the UpdateRotation operation.
iv_timezoneid TYPE /AWS1/SMCTIMEZONEID /AWS1/SMCTIMEZONEID¶
The time zone to base the rotation’s activity on in Internet Assigned Numbers Authority (IANA) format. For example: "America/Los_Angeles", "UTC", or "Asia/Seoul". For more information, see the Time Zone Database on the IANA website.
Designators for time zones that don’t support Daylight Savings Time rules, such as Pacific Standard Time (PST), are not supported.
io_recurrence TYPE REF TO /AWS1/CL_SMCRECURRENCESETTINGS /AWS1/CL_SMCRECURRENCESETTINGS¶
Information about the rule that specifies when a shift's team members rotate.
Optional arguments:¶
iv_starttime TYPE /AWS1/SMCDATETIME /AWS1/SMCDATETIME¶
The date and time that the rotation goes into effect.
it_tags TYPE /AWS1/CL_SMCTAG=>TT_TAGSLIST TT_TAGSLIST¶
Optional metadata to assign to the rotation. Tags enable you to categorize a resource in different ways, such as by purpose, owner, or environment. For more information, see Tagging Incident Manager resources in the Incident Manager User Guide.
iv_idempotencytoken TYPE /AWS1/SMCIDEMPOTENCYTOKEN /AWS1/SMCIDEMPOTENCYTOKEN¶
A token that ensures that the operation is called only once with the specified details.
RETURNING¶
oo_output TYPE REF TO /aws1/cl_smccreaterotationrslt /AWS1/CL_SMCCREATEROTATIONRSLT¶
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->createrotation(
io_recurrence = new /aws1/cl_smcrecurrencesettings(
it_dailysettings = VALUE /aws1/cl_smchandofftime=>tt_dailysettings(
(
new /aws1/cl_smchandofftime(
iv_hourofday = 123
iv_minuteofhour = 123
)
)
)
it_monthlysettings = VALUE /aws1/cl_smcmonthlysetting=>tt_monthlysettings(
(
new /aws1/cl_smcmonthlysetting(
io_handofftime = new /aws1/cl_smchandofftime(
iv_hourofday = 123
iv_minuteofhour = 123
)
iv_dayofmonth = 123
)
)
)
it_shiftcoverages = VALUE /aws1/cl_smccoveragetime=>tt_shiftcoveragesmap(
(
VALUE /aws1/cl_smccoveragetime=>ts_shiftcoveragesmap_maprow(
key = |string|
value = VALUE /aws1/cl_smccoveragetime=>tt_coveragetimes(
(
new /aws1/cl_smccoveragetime(
io_end = new /aws1/cl_smchandofftime(
iv_hourofday = 123
iv_minuteofhour = 123
)
io_start = new /aws1/cl_smchandofftime(
iv_hourofday = 123
iv_minuteofhour = 123
)
)
)
)
)
)
)
it_weeklysettings = VALUE /aws1/cl_smcweeklysetting=>tt_weeklysettings(
(
new /aws1/cl_smcweeklysetting(
io_handofftime = new /aws1/cl_smchandofftime(
iv_hourofday = 123
iv_minuteofhour = 123
)
iv_dayofweek = |string|
)
)
)
iv_numberofoncalls = 123
iv_recurrencemultiplier = 123
)
it_contactids = VALUE /aws1/cl_smcrotationcontacts00=>tt_rotationcontactsarnlist(
( new /aws1/cl_smcrotationcontacts00( |string| ) )
)
it_tags = VALUE /aws1/cl_smctag=>tt_tagslist(
(
new /aws1/cl_smctag(
iv_key = |string|
iv_value = |string|
)
)
)
iv_idempotencytoken = |string|
iv_name = |string|
iv_starttime = '20150101000000.0000000'
iv_timezoneid = |string|
).
This is an example of reading all possible response values
lo_result = lo_result.
IF lo_result IS NOT INITIAL.
lv_ssmcontactsarn = lo_result->get_rotationarn( ).
ENDIF.