All Classes Namespaces Files Functions Variables Groups
Alarms.idl
1 /**
2  * @file Events.idl
3  * @brief Calendar Events, Exceptions, Recurrence
4  *
5  * @author Marek Sykora, Dusan Juhas
6  *
7  * @copyright Copyright © 2017 Kerio Technologies s.r.o.
8  */
9 
10 #import <Calendars.idl>
11 
12 module kerio {
13 module jsonapi {
14 module webmail {
15 module alarms {
16 
17 struct Alarm {
18  ItemType type; ///< [READ-ONLY] only 'Calendar' and 'Task' are valid
19  kerio::web::KId itemId; ///< [READ-ONLY] global identification of occurrence
20  kerio::web::KId baseId; ///< [READ-ONLY] global identification of event or task
21  string summary; ///< [READ-ONLY]
22  string location; ///< [READ-ONLY]
23  UtcDateTime start; ///< [READ-ONLY] can be empty in case of item 'Task'
24  UtcDateTime end; ///< [READ-ONLY] can be empty in case of item 'Task'. In case of an all day event is there begin of next day.
25  UtcDateTime due; ///< [READ-ONLY] can be empty and is valid only for item 'Task'.
26  boolean isAllDay; ///< [READ-ONLY]
27  UtcDateTime reminderTime; ///< time when remainder should appear
28 };
29 
30 typedef sequence<Alarm> AlarmList;
31 
32 interface Alarms {
33 
34  /**
35  * Dismiss alarms.
36  * Value X-NEXT-ALARM is set to the start of next occurence in case of recurrent event.
37  * If ID of ordinary event or ID of last occurrence of recurrent event is passed into
38  * the method then a reminder will be removed as well as this value.
39  *
40  * @param errors - list of errors
41  * @param itemIds - list of event or occurrence IDs
42  */
43  void dismiss(out kerio::web::ErrorList errors, in kerio::web::KIdList itemIds);
44 
45  /**
46  * Get alarms. Alarms are searched in range from now to value 'until'.
47  *
48  * @param list - list of alarms
49  * @param since - lower bound of time range
50  * @param until - upper bound of time range
51  */
52  void get(out AlarmList list, in UtcTime since, in UtcTime until);
53 
54  /**
55  * Set alarm to a particular time.
56  * Value is placed in X-NEXT-ALARM property.
57  *
58  * @param errors - list of errors
59  * @param nextTime - time
60  * @param itemIds - list of event or occurrence IDs
61  */
62  void set(out kerio::web::ErrorList errors, in UtcTime nextTime, in kerio::web::KIdList itemIds);
63 };
64 
65 }; }; }; }; // end of namespace
66