diff options
author | Federico Mena Quintero <federico@helixcode.com> | 2000-02-08 15:08:29 +0800 |
---|---|---|
committer | Arturo Espinosa <unammx@src.gnome.org> | 2000-02-08 15:08:29 +0800 |
commit | cc670cb2ca319599eebac658f1164dbb64d70c65 (patch) | |
tree | 55dc72c7ea1b1582158e8aa55eedb9d18a4ab4e4 /calendar/idl | |
parent | c02660b4081a84c9ad5749a931f5458f08f634d3 (diff) | |
download | gsoc2013-evolution-cc670cb2ca319599eebac658f1164dbb64d70c65.tar.gz gsoc2013-evolution-cc670cb2ca319599eebac658f1164dbb64d70c65.tar.zst gsoc2013-evolution-cc670cb2ca319599eebac658f1164dbb64d70c65.zip |
New struct to wrap instances of calendar objects for recurrencies and
2000-02-08 Federico Mena Quintero <federico@helixcode.com>
* evolution-calendar.idl (CalObjInstance): New struct to wrap
instances of calendar objects for recurrencies and alarms.
(Cal::get_events_in_range): New method to get ocurring and
recurring events by time range.
* cal-backend.c (cal_backend_get_events_in_range): New function to
get a list of event instances in a time range.
(string_from_ical_object): New internal function.
(cal_backend_get_object): Use string_from_ical_object() instead of
doing everything ourselves.
(cal_backend_get_events_in_range): New function to get a list of
the events that occur or recur in a specified time range.
* cal-client.c (cal_client_get_events_in_range): Implemented
client-side function.
* cal-util.h:
* cal-util.c: New files with utilities and types common to the
client and server parts.
(CalObjInstance): New structure to hold an instance of an actual
occurrence, recurrence, or alarm trigger of a calendar object.
(cal_obj_instance_list_free): New function to free a list of
calendar object instances.
* cal.c (Cal_get_events_in_range): Implemented new method.
* corba-cal.c (cal_repo_get_updated_objects): Free `str' with
free(), not g_free(), since calendar_get_as_vcal_string() uses
writeMemVObject(), which uses realloc(). Fixed in gnome-pim as
well.
svn path=/trunk/; revision=1693
Diffstat (limited to 'calendar/idl')
-rw-r--r-- | calendar/idl/evolution-calendar.idl | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/calendar/idl/evolution-calendar.idl b/calendar/idl/evolution-calendar.idl index 6746eb66a1..8b9878d78e 100644 --- a/calendar/idl/evolution-calendar.idl +++ b/calendar/idl/evolution-calendar.idl @@ -23,11 +23,29 @@ module Calendar { /* An unique identifier for a calendar object */ typedef string CalObjUID; + /* Used to store a time_t */ + typedef unsigned long Time_t; + + /* An instance of a calendar object that actually occurs. These are + * "virtual" objects in that they are used to represent instances of + * recurring events and alarms. "Real" objects just contain the + * information required to figure out the times at which they recur or + * trigger. + */ + struct CalObjInstance { + CalObj calobj; + Time_t start; + Time_t end; + }; + + typedef sequence<CalObjInstance> CalObjInstanceSeq; + interface Listener; /* Calendar client interface */ interface Cal : Bonobo::Unknown { exception NotFound {}; + exception InvalidRange {}; /* A calendar is identified by its URI */ readonly attribute string uri; @@ -35,6 +53,10 @@ module Calendar { /* Gets an object based on its URI */ CalObj get_object (in CalObjUID uid) raises (NotFound); + + /* Gets the events that occur or recur in the specified time range */ + CalObjInstanceSeq get_events_in_range (in Time_t start, in Time_t end) + raises (InvalidRange); }; /* Listener for changes in a calendar */ |