0001-Add-protos-for-interaction-with-a-calendaring-applic.patch
proto/sandbox/rst/calendar/CalendarList.proto | ||
---|---|---|
1 |
package rst.calendar; |
|
2 | ||
3 |
option java_outer_classname = "CalendarListType"; |
|
4 | ||
5 |
/** |
|
6 |
* A List of available calendars. |
|
7 |
* |
|
8 |
* @author Viktor Richter <vrichter@techfak.uni-bielefeld.de> |
|
9 |
*/ |
|
10 |
message CalendarList { |
|
11 | ||
12 |
/** |
|
13 |
* A List of calender info objects. |
|
14 |
*/ |
|
15 |
repeated string calendar_id = 1; |
|
16 | ||
17 |
} |
proto/sandbox/rst/calendar/CalendarRequest.proto | ||
---|---|---|
1 |
package rst.calendar; |
|
2 | ||
3 |
option java_outer_classname = "CalendarRequestType"; |
|
4 | ||
5 |
import "rst/calendar/DateTime.proto"; |
|
6 | ||
7 |
/** |
|
8 |
* A request for calendar data. |
|
9 |
* |
|
10 |
* @author Viktor Richter <vrichter@techfak.uni-bielefeld.de> |
|
11 |
*/ |
|
12 |
message CalendarRequest { |
|
13 | ||
14 |
/** |
|
15 |
* Ignore calendar components before start time. |
|
16 |
*/ |
|
17 |
optional DateTime start_time = 1; |
|
18 | ||
19 |
/** |
|
20 |
* Ignore calendar components afrer end time. |
|
21 |
*/ |
|
22 |
optional DateTime end_time = 2; |
|
23 | ||
24 |
/** |
|
25 |
* Search for todo entries. |
|
26 |
*/ |
|
27 |
optional bool search_todos = 3 [default = true]; |
|
28 | ||
29 |
/** |
|
30 |
* Search for event entries. |
|
31 |
*/ |
|
32 |
optional bool search_events = 4 [default = true]; |
|
33 | ||
34 |
/** |
|
35 |
* If this is true each entry which is between start and |
|
36 |
* end date will be additionally augmented with a list of |
|
37 |
* time periods in which it occurs. |
|
38 |
*/ |
|
39 |
required bool calculate_time_periods = 5 [default = false]; |
|
40 | ||
41 |
} |
proto/sandbox/rst/calendar/CalendarResult.proto | ||
---|---|---|
1 |
package rst.calendar; |
|
2 | ||
3 |
option java_outer_classname = "CalendarResultType"; |
|
4 | ||
5 |
import "rst/calendar/DateTime.proto"; |
|
6 |
import "rst/calendar/Event.proto"; |
|
7 |
import "rst/calendar/Todo.proto"; |
|
8 |
import "rst/calendar/TimeZone.proto"; |
|
9 | ||
10 |
/** |
|
11 |
* The answer to a CalendarRequest. |
|
12 |
* |
|
13 |
* @author Viktor Richter <vrichter@techfak.uni-bielefeld.de> |
|
14 |
*/ |
|
15 |
message CalendarResult { |
|
16 | ||
17 |
/** |
|
18 |
* Describes one specific time period. |
|
19 |
*/ |
|
20 |
message TimePeriod { |
|
21 | ||
22 |
/** |
|
23 |
* When the time period starts. |
|
24 |
*/ |
|
25 |
required DateTime start = 1; |
|
26 | ||
27 |
/** |
|
28 |
* When the time period ends. |
|
29 |
*/ |
|
30 |
required DateTime end = 2; |
|
31 |
} |
|
32 | ||
33 |
/** |
|
34 |
* Describes an event and optionally all of its occurances. |
|
35 |
*/ |
|
36 |
message EventWithTimes { |
|
37 | ||
38 |
/** |
|
39 |
* The event description. |
|
40 |
*/ |
|
41 |
required Event event = 1; |
|
42 | ||
43 |
/** |
|
44 |
* Time periods where this event applies to. |
|
45 |
*/ |
|
46 |
repeated TimePeriod time = 2; |
|
47 | ||
48 |
} |
|
49 | ||
50 |
/** |
|
51 |
* THe obligatory list of timezones needed by the events and todos |
|
52 |
* contained in this message. |
|
53 |
*/ |
|
54 |
repeated TimeZone timezone = 1; |
|
55 | ||
56 |
/** |
|
57 |
* A list of events that match the correesponding CalendarRequest |
|
58 |
* and their occurrence times (when requested). |
|
59 |
*/ |
|
60 |
repeated EventWithTimes event = 2; |
|
61 | ||
62 |
/** |
|
63 |
* A list of todos that match the correesponding CalendarRequest. |
|
64 |
*/ |
|
65 |
repeated Todo todo = 3; |
|
66 | ||
67 | ||
68 |
} |
proto/sandbox/rst/calendar/CalendarUpdate.proto | ||
---|---|---|
1 |
package rst.calendar; |
|
2 | ||
3 |
option java_outer_classname = "CalendarUpdateType"; |
|
4 | ||
5 |
import "rst/calendar/Event.proto"; |
|
6 |
import "rst/calendar/Todo.proto"; |
|
7 |
import "rst/calendar/TimeZone.proto"; |
|
8 | ||
9 |
/** |
|
10 |
* Describes the changes between two calendar versions. |
|
11 |
* |
|
12 |
* @author Viktor Richter <vrichter@techfak.uni-bielefeld.de> |
|
13 |
*/ |
|
14 |
message CalendarUpdate { |
|
15 | ||
16 |
/** |
|
17 |
* A set of TimeZones needed by the events and todos in this message. |
|
18 |
*/ |
|
19 |
repeated TimeZone timezones = 3; |
|
20 | ||
21 |
/** |
|
22 |
* A set of Events which changed between the two versons. |
|
23 |
*/ |
|
24 |
repeated Event changed_events = 4; |
|
25 | ||
26 |
/** |
|
27 |
* A set of Todos which changed between the two versons. |
|
28 |
*/ |
|
29 |
repeated Todo changed_todos = 5; |
|
30 | ||
31 |
/** |
|
32 |
* A set of ids of entries (todos and events) which were removed between the two versons. |
|
33 |
*/ |
|
34 |
repeated string removed_entry_ids = 6; |
|
35 |
} |
|
0 |
- |