Top | ![]() |
![]() |
![]() |
![]() |
This is the main user facing interface used for representing an event or other component in a given calendar.
ECalComponent *
e_cal_component_new (void
);
Creates a new empty calendar component object. Once created, you should set it from an
existing icalcomponent structure by using e_cal_component_set_icalcomponent()
or with a
new empty component type by using e_cal_component_set_new_vtype()
.
Since: 3.34
ECalComponent *
e_cal_component_new_vtype (ECalComponentVType vtype
);
Creates a new ECalComponent of type vtype
.
Since: 3.34
ECalComponent *
e_cal_component_new_from_string (const gchar *calobj
);
Creates a new calendar component object from the given iCalendar string.
A calendar component representing the given iCalendar string on success, NULL if there was an error.
[transfer full]
Since: 3.34
ECalComponent *
e_cal_component_new_from_icalcomponent
(ICalComponent *icalcomp
);
Creates a new ECalComponent which will has set icalcomp
as
an inner ICalComponent. The newly created ECalComponent takes
ownership of the icalcomp
, and if the call
to e_cal_component_set_icalcomponent()
fails, then icalcomp
is freed.
An ECalComponent with icalcomp
assigned on success,
NULL if the icalcomp
cannot be assigned to ECalComponent.
[transfer full]
Since: 3.34
ECalComponent *
e_cal_component_clone (ECalComponent *comp
);
Creates a new calendar component object by copying the information from another one.
A newly-created calendar component with the same values as the original one.
[transfer full]
Since: 3.34
void e_cal_component_set_new_vtype (ECalComponent *comp
,ECalComponentVType type
);
Clears any existing component data from a calendar component object and creates a new ICalComponent of the specified type for it. The only property that will be set in the new component will be its unique identifier.
Since: 3.34
ECalComponentVType
e_cal_component_get_vtype (ECalComponent *comp
);
Queries the type of a calendar component object.
Since: 3.34
ICalComponent *
e_cal_component_get_icalcomponent (ECalComponent *comp
);
Queries the icalcomponent structure that a calendar component object is wrapping.
An ICalComponent structure, or NULL
if the comp
has no ICalComponent set to it.
[transfer none][nullable]
Since: 3.34
gboolean e_cal_component_set_icalcomponent (ECalComponent *comp
,ICalComponent *icalcomp
);
Sets the contents of a calendar component object from an ICalComponent.
If the comp
already had an ICalComponent set into it, it will
be freed automatically.
Supported component types are VEVENT, VTODO, VJOURNAL, VFREEBUSY, and VTIMEZONE.
Since: 3.34
void
e_cal_component_strip_errors (ECalComponent *comp
);
Strips all error messages from the calendar component. Those error messages are added to the iCalendar string representation whenever an invalid is used for one of its fields.
Since: 3.34
gchar *
e_cal_component_get_as_string (ECalComponent *comp
);
Gets the iCalendar string representation of a calendar component. You should
call e_cal_component_commit_sequence()
before this function to ensure that the
component's sequence number is consistent with the state of the object.
Since: 3.34
void
e_cal_component_commit_sequence (ECalComponent *comp
);
Increments the sequence number property in a calendar component object if it needs it. This needs to be done when any of a number of properties listed in RFC 2445 change values, such as the start and end dates of a component.
This function must be called before calling e_cal_component_get_as_string()
to
ensure that the component is fully consistent.
Since: 3.34
void
e_cal_component_abort_sequence (ECalComponent *comp
);
Aborts the sequence change needed in the given calendar component,
which means it will not require a sequence commit (via
e_cal_component_commit_sequence()
) even if the changes done require a
sequence increment.
Since: 3.34
const gchar *
e_cal_component_get_uid (ECalComponent *comp
);
Queries the unique identifier of a calendar component object.
Since: 3.34
void e_cal_component_set_uid (ECalComponent *comp
,const gchar *uid
);
Sets the unique identifier string of a calendar component object.
Since: 3.34
ECalComponentId *
e_cal_component_get_id (ECalComponent *comp
);
Get the ID of the component as an ECalComponentId. The return value should
be freed with e_cal_component_id_free()
, when no longer needed.
Since: 3.34
gchar *
e_cal_component_get_categories (ECalComponent *comp
);
Queries the categories of the given calendar component. The categories
are returned in the categories
argument, which, on success, will contain
a comma-separated list of all categories set in the component.
Free the returned string with g_free()
, when no longer needed.
Since: 3.34
void e_cal_component_set_categories (ECalComponent *comp
,const gchar *categories
);
Sets the list of categories for a calendar component.
Since: 3.34
void e_cal_component_set_categories_list (ECalComponent *comp
,const GSList *categ_list
);
Sets the list of categories of a calendar component object.
comp |
A calendar component object. |
|
categ_list |
List of strings, one for each category. |
[element-type utf8] |
Since: 3.34
ECalComponentClassification
e_cal_component_get_classification (ECalComponent *comp
);
Queries the classification of a calendar component object. If the classification property is not set on this component, this function returns E_CAL_COMPONENT_CLASS_NONE.
Retuurns: a classification of the comp
, as an ECalComponentClassification
Since: 3.34
void e_cal_component_set_classification (ECalComponent *comp
,ECalComponentClassification classif
);
Sets the classification property of a calendar component object. To unset
the property, specify E_CAL_COMPONENT_CLASS_NONE for classif
.
Since: 3.34
GSList *
e_cal_component_get_comments (ECalComponent *comp
);
Queries the comments of a calendar component object. The comment property can appear several times inside a calendar component, and so a list of ECalComponentText is returned. Free the returned GSList with g_slist_free_full (slist, e_cal_component_text_free);, when no longer needed.
the comment properties
and their parameters, as a list of ECalComponentText structures; or NULL
, when
the component doesn't contain any.
[transfer full][element-type ECalComponentText][nullable]
Since: 3.34
void e_cal_component_set_comments (ECalComponent *comp
,const GSList *text_list
);
Sets the comments of a calendar component object. The comment property can appear several times inside a calendar component, and so a list of ECalComponentText structures is used.
comp |
A calendar component object. |
|
text_list |
List of ECalComponentText structures. |
[element-type ECalComponentText] |
Since: 3.34
ICalTime *
e_cal_component_get_completed (ECalComponent *comp
);
Queries the date at which a calendar compoment object was completed.
Free the returned non-NULL pointer with g_object_unref()
, when
no longer needed.
Since: 3.34
void e_cal_component_set_completed (ECalComponent *comp
,const ICalTime *tt
);
Sets the date at which a calendar component object was completed.
Since: 3.34
GSList *
e_cal_component_get_contacts (ECalComponent *comp
);
Queries the contact of a calendar component object. The contact property can appear several times inside a calendar component, and so a list of ECalComponentText is returned. Free the returned GSList with g_slist_free_full (slist, e_cal_component_text_free);, when no longer needed.
the contact properties and their parameters, as a GSList of ECalComponentText structures.
[transfer full][element-type ECalComponentText]
Since: 3.34
void e_cal_component_set_contacts (ECalComponent *comp
,const GSList *text_list
);
Sets the contact of a calendar component object. The contact property can appear several times inside a calendar component, and so a list of ECalComponentText structures is used.
comp |
A calendar component object. |
|
text_list |
List of ECalComponentText structures. |
[element-type ECalComponentText] |
Since: 3.34
ICalTime *
e_cal_component_get_created (ECalComponent *comp
);
Queries the date in which a calendar component object was created in the
calendar store. Free the returned non-NULL pointer with g_object_unref()
, when
no longer needed.
Since: 3.34
void e_cal_component_set_created (ECalComponent *comp
,const ICalTime *tt
);
Sets the date in which a calendar component object is created in the calendar store. This should only be used inside a calendar store application, i.e. not by calendar user agents.
Since: 3.34
GSList *
e_cal_component_get_descriptions (ECalComponent *comp
);
Queries the description of a calendar component object. Journal components may have more than one description, and as such this function returns a list of ECalComponentText structures. All other types of components can have at most one description. Free the returned GSList with g_slist_free_full (slist, e_cal_component_text_free);, when no longer needed.
the description properties and their parameters, as a GSList of ECalComponentText structures.
[transfer full][element-type ECalComponentText][nullable]
Since: 3.34
void e_cal_component_set_descriptions (ECalComponent *comp
,const GSList *text_list
);
Sets the description of a calendar component object. Journal components may have more than one description, and as such this function takes in a list of ECalComponentText structures. All other types of components can have at most one description.
comp |
A calendar component object. |
|
text_list |
List of ECalComponentText structures. |
[element-type ECalComponentText] |
Since: 3.34
ECalComponentDateTime *
e_cal_component_get_dtend (ECalComponent *comp
);
Queries the date/time end of a calendar component object. In case there's no DTEND,
but only DTSTART and DURATION, then the end is computed from the later two.
Free the returned ECalComponentDateTime with e_cal_component_datetime_free()
,
when no longer needed.
Since: 3.34
void e_cal_component_set_dtend (ECalComponent *comp
,const ECalComponentDateTime *dt
);
Sets the date/time end property of a calendar component object.
comp |
A calendar component object. |
|
dt |
End date/time, or |
[nullable] |
Since: 3.34
ICalTime *
e_cal_component_get_dtstamp (ECalComponent *comp
);
Queries the date/timestamp property of a calendar component object, which is the last time at which the object was modified by a calendar user agent.
Free a non-NULL returned object with g_object_unref()
,
when no longer needed.
Since: 3.34
void e_cal_component_set_dtstamp (ECalComponent *comp
,const ICalTime *tt
);
Sets the date/timestamp of a calendar component object. This should be called whenever a calendar user agent makes a change to a component's properties.
Since: 3.34
ECalComponentDateTime *
e_cal_component_get_dtstart (ECalComponent *comp
);
Queries the date/time start of a calendar component object.
Free the returned ECalComponentDateTime with e_cal_component_datetime_free()
,
when no longer needed.
Since: 3.34
void e_cal_component_set_dtstart (ECalComponent *comp
,const ECalComponentDateTime *dt
);
Sets the date/time start property of a calendar component object.
comp |
A calendar component object. |
|
dt |
Start date/time, or |
[nullable] |
Since: 3.34
ECalComponentDateTime *
e_cal_component_get_due (ECalComponent *comp
);
Queries the due date/time of a calendar component object. In case there's no DUE,
but only DTSTART and DURATION, then the due is computed from the later two.
Free the returned ECalComponentDateTime with e_cal_component_datetime_free()
,
when no longer needed.
Since: 3.34
void e_cal_component_set_due (ECalComponent *comp
,const ECalComponentDateTime *dt
);
Sets the due date/time property of a calendar component object.
comp |
A calendar component object. |
|
dt |
End date/time, or |
[nullable] |
Since: 3.34
GSList *
e_cal_component_get_exdates (ECalComponent *comp
);
Queries the list of exception date properties in a calendar component object. Free the returned GSList with g_slist_free_full (exdates, e_cal_component_datetime_free);, when no longer needed.
the list of exception dates, as a GSList of ECalComponentDateTime.
[transfer full][nullable][element-type ECalComponentDateTime]
Since: 3.34
void e_cal_component_set_exdates (ECalComponent *comp
,const GSList *exdate_list
);
Sets the list of exception dates in a calendar component object.
comp |
A calendar component object. |
|
exdate_list |
List of ECalComponentDateTime structures. |
[nullable][element-type ECalComponentDateTime] |
Since: 3.34
gboolean
e_cal_component_has_exdates (ECalComponent *comp
);
Queries whether a calendar component object has any exception dates defined for it.
Since: 3.34
GSList *
e_cal_component_get_exrules (ECalComponent *comp
);
Queries the list of exception rule properties of a calendar component object. Free the returned list with g_slist_free_full (slist, g_object_unref);, when no longer needed.
a GSList
of exception rules as ICalRecurrence structures, or NULL
, when none exist.
[transfer full][nullable][element-type ICalRecurrence]
Since: 3.34
void e_cal_component_set_exrules (ECalComponent *comp
,const GSList *recur_list
);
Sets the list of exception rules in a calendar component object.
comp |
A calendar component object. |
|
recur_list |
a GSList
of ICalRecurrence structures, or |
[nullable][element-type ICalRecurrence] |
Since: 3.34
gboolean
e_cal_component_has_exrules (ECalComponent *comp
);
Queries whether a calendar component object has any exception rules defined for it.
Since: 3.34
gboolean
e_cal_component_has_exceptions (ECalComponent *comp
);
Queries whether a calendar component object has any exception dates or exception rules.
Since: 3.34
ICalGeo *
e_cal_component_get_geo (ECalComponent *comp
);
Gets the geographic position property of a calendar component object.
Free the returned non-NULL object with g_object_unref()
, when
no longer needed.
Since: 3.34
void e_cal_component_set_geo (ECalComponent *comp
,const ICalGeo *geo
);
Sets the geographic position property on a calendar component object.
comp |
A calendar component object. |
|
geo |
Value for the geographic position property, or |
[nullable] |
Since: 3.34
ICalTime *
e_cal_component_get_last_modified (ECalComponent *comp
);
Queries the time at which a calendar component object was last modified in
the calendar store. Free the returned non-NULL pointer with g_object_unref()
,
when no longer needed.
Since: 3.34
void e_cal_component_set_last_modified (ECalComponent *comp
,const ICalTime *tt
);
Sets the time at which a calendar component object was last stored in the calendar store. This should not be called by plain calendar user agents.
Since: 3.34
ECalComponentOrganizer *
e_cal_component_get_organizer (ECalComponent *comp
);
Queries the organizer property of a calendar component object.
Free the returned structure with e_cal_component_organizer_free()
,
when no longer needed.
an ECalComponentOrganizer structure
destribing the organizer, or NULL
, when none exists.
[transfer full][nullable]
Since: 3.34
void e_cal_component_set_organizer (ECalComponent *comp
,const ECalComponentOrganizer *organizer
);
Sets the organizer of a calendar component object
comp |
A calendar component object. |
|
organizer |
Value for the organizer property, as an ECalComponentOrganizer. |
[nullable] |
Since: 3.34
gboolean
e_cal_component_has_organizer (ECalComponent *comp
);
Check whether a calendar component object has an organizer or not.
Since: 3.34
gint
e_cal_component_get_percent_complete (ECalComponent *comp
);
Queries the percent-complete property of a calendar component object.
Since: 3.34
void e_cal_component_set_percent_complete (ECalComponent *comp
,gint percent
);
Sets percent complete. The percent
can be between 0 and 100, inclusive.
A special value -1 can be used to remove the percent complete property.
Since: 3.34
gint
e_cal_component_get_priority (ECalComponent *comp
);
Queries the priority property of a calendar component object.
Since: 3.34
void e_cal_component_set_priority (ECalComponent *comp
,gint priority
);
Sets the priority property of a calendar component object.
The priority
can be between 0 and 9, inclusive.
A special value -1 can be used to remove the priority property.
Since: 3.34
ECalComponentRange *
e_cal_component_get_recurid (ECalComponent *comp
);
Queries the recurrence id property of a calendar component object.
Free the returned ECalComponentRange with e_cal_component_range_free()
,
whe no longer needed.
Since: 3.34
gchar *
e_cal_component_get_recurid_as_string (ECalComponent *comp
);
Gets the recurrence ID property as a string.
Since: 3.34
void e_cal_component_set_recurid (ECalComponent *comp
,const ECalComponentRange *recur_id
);
Sets the recurrence id property of a calendar component object.
comp |
A calendar component object. |
|
recur_id |
Value for the recurrence id property, or |
[nullable] |
Since: 3.34
GSList *
e_cal_component_get_rdates (ECalComponent *comp
);
Queries the list of recurrence date properties in a calendar component object. Free the returned GSList with g_slist_free_full (slist, e_cal_component_period_free);, when no longer needed.
the list of recurrence dates, as a GSList of ECalComponentPeriod structures.
[transfer full][nullable][element-type ECalComponentPeriod]
Since: 3.34
void e_cal_component_set_rdates (ECalComponent *comp
,const GSList *rdate_list
);
Sets the list of recurrence dates in a calendar component object.
comp |
A calendar component object. |
|
rdate_list |
List of
ECalComponentPeriod structures, or |
[nullable][element-type ECalComponentPeriod] |
Since: 3.34
gboolean
e_cal_component_has_rdates (ECalComponent *comp
);
Queries whether a calendar component object has any recurrence dates defined for it.
Since: 3.34
GSList *
e_cal_component_get_rrules (ECalComponent *comp
);
Queries the list of recurrence rule properties of a calendar component object. Free the returned list with g_slist_free_full (slist, g_object_unref);, when no longer needed.
a GSList
of recurrence rules as ICalRecurrence structures, or NULL
, when none exist.
[transfer full][nullable][element-type ICalRecurrence]
Since: 3.34
void e_cal_component_set_rrules (ECalComponent *comp
,const GSList *recur_list
);
Sets the list of recurrence rules in a calendar component object.
comp |
A calendar component object. |
|
recur_list |
List of ICalRecurrence structures, or |
[nullable][element-type ICalRecurrence] |
Since: 3.34
gboolean
e_cal_component_has_rrules (ECalComponent *comp
);
Queries whether a calendar component object has any recurrence rules defined for it.
Since: 3.34
gboolean
e_cal_component_has_recurrences (ECalComponent *comp
);
Queries whether a calendar component object has any recurrence dates or recurrence rules.
Since: 3.34
gboolean
e_cal_component_has_simple_recurrence (ECalComponent *comp
);
Checks whether the given calendar component object has simple recurrence rules or more complicated ones.
Since: 3.34
gboolean
e_cal_component_is_instance (ECalComponent *comp
);
Checks whether a calendar component object is an instance of a recurring event.
Since: 3.34
gint
e_cal_component_get_sequence (ECalComponent *comp
);
Queries the sequence number of a calendar component object.
Since: 3.34
void e_cal_component_set_sequence (ECalComponent *comp
,gint sequence
);
Sets the sequence number of a calendar component object. A special value -1 can be used to remove the sequence number property.
Normally this function should not be called, since the sequence number is incremented automatically at the proper times.
comp |
A calendar component object. |
|
sequence |
a sequence number to set, or -1 to remove the property |
Since: 3.34
ICalPropertyStatus
e_cal_component_get_status (ECalComponent *comp
);
Queries the status property of a calendar component object.
Since: 3.34
void e_cal_component_set_status (ECalComponent *comp
,ICalPropertyStatus status
);
Sets the status property of a calendar component object.
comp |
A calendar component object. |
|
status |
Status value, as an ICalPropertyStatus. Use |
Since: 3.34
ECalComponentText *
e_cal_component_get_summary (ECalComponent *comp
);
Queries the summary of a calendar component object.
Free the returned pointer withe_cal_component_text_free()
,
when no longer needed.
Since: 3.34
void e_cal_component_set_summary (ECalComponent *comp
,const ECalComponentText *summary
);
Sets the summary of a calendar component object.
Since: 3.34
ECalComponentTransparency
e_cal_component_get_transparency (ECalComponent *comp
);
Queries the time transparency of a calendar component object.
the time transparency, as an ECalComponentTransparency; value E_CAL_COMPONENT_TRANSP_NONE is returned when none is set
Since: 3.34
void e_cal_component_set_transparency (ECalComponent *comp
,ECalComponentTransparency transp
);
Sets the time transparency of a calendar component object.
Use E_CAL_COMPONENT_TRANSP_NONE
to unset the property.
Since: 3.34
gchar *
e_cal_component_get_url (ECalComponent *comp
);
Queries the uniform resource locator property of a calendar component object.
Free the returned URL with g_free()
, when no longer needed.
Since: 3.34
void e_cal_component_set_url (ECalComponent *comp
,const gchar *url
);
Sets the uniform resource locator property of a calendar component object.
A NULL
or an empty string removes the property.
Since: 3.34
GSList *
e_cal_component_get_attendees (ECalComponent *comp
);
Queries the attendee properties of the calendar component object. Free the returned GSList with g_slist_free_full (slist, e_cal_component_attendee_free);, when no longer needed.
the attendees, as a GSList of an ECalComponentAttendee, or NULL
,
when none are set.
[transfer full][nullable][element-type ECalComponentAttendee]
Since: 3.34
void e_cal_component_set_attendees (ECalComponent *comp
,const GSList *attendee_list
);
Sets the attendees of a calendar component object
comp |
A calendar component object. |
|
attendee_list |
Values for attendee
properties, or |
[nullable][element-type ECalComponentAttendee] |
Since: 3.34
gboolean
e_cal_component_has_attendees (ECalComponent *comp
);
Queries a calendar component object for the existence of attendees.
Since: 3.34
gchar *
e_cal_component_get_location (ECalComponent *comp
);
Queries the location property of a calendar component object.
Since: 3.34
void e_cal_component_set_location (ECalComponent *comp
,const gchar *location
);
Sets the location property of a calendar component object.
comp |
A calendar component object. |
|
location |
Location value. Use |
[nullable] |
Since: 3.34
GSList *
e_cal_component_get_attachments (ECalComponent *comp
);
Queries the attachment properties as ICalAttach objects of the calendar component object. Changes on these objects are directly affecting the component. Free the returned GSList with g_slist_free_full (slist, g_object_unref);, when no longer needed.
a GSList of attachments, as ICalAttach objects.
[transfer full][nullable][element-type ICalAttach]
Since: 3.34
void e_cal_component_set_attachments (ECalComponent *comp
,const GSList *attachments
);
Sets the attachments of the calendar component object.
comp |
A calendar component object |
|
attachments |
a GSList of an ICalAttach,
or |
[nullable][element-type ICalAttach] |
Since: 3.34
gboolean
e_cal_component_has_attachments (ECalComponent *comp
);
Queries the component to see if it has attachments.
Since: 3.34
gboolean
e_cal_component_has_alarms (ECalComponent *comp
);
Checks whether the component has any alarms.
Since: 3.34
void e_cal_component_add_alarm (ECalComponent *comp
,ECalComponentAlarm *alarm
);
Adds an alarm subcomponent to a calendar component. You should have created
the alarm
by using e_cal_component_alarm_new()
; it is invalid to use an
ECalComponentAlarm structure that came from e_cal_component_get_alarm()
. After
adding the alarm, the alarm
structure is no longer valid because the
internal structures may change and you should get rid of it by using
e_cal_component_alarm_free()
.
Since: 3.34
void e_cal_component_remove_alarm (ECalComponent *comp
,const gchar *auid
);
Removes an alarm subcomponent from a calendar component. If the alarm that
corresponds to the specified auid
had been fetched with
e_cal_component_get_alarm()
, then those alarm structures will be invalid; you
should get rid of them with e_cal_component_alarm_free()
before using this
function.
Since: 3.34
void
e_cal_component_remove_all_alarms (ECalComponent *comp
);
Remove all alarms from the calendar component
Since: 3.34
GSList *
e_cal_component_get_alarm_uids (ECalComponent *comp
);
Builds a list of the unique identifiers of the alarm subcomponents inside a calendar component. Free the returned GSList with g_slist_free_full (slist, g_free);, when no longer needed.
Since: 3.34
ECalComponentAlarm * e_cal_component_get_alarm (ECalComponent *comp
,const gchar *auid
);
Queries a particular alarm subcomponent of a calendar component.
Free the returned pointer with e_cal_component_alarm_free()
,
when no longer needed.
the alarm subcomponent that corresponds
to the specified auid
, or NULL
if no alarm exists with that UID.
[transfer full][nullable]
Since: 3.34
GSList *
e_cal_component_get_all_alarms (ECalComponent *comp
);
Queries all alarm subcomponents of a calendar component. Free the returned GSList with g_slist_free_full (slist, e_cal_component_alarm_free);, when no longer needed.
the alarm subcomponents
as a GSList of ECalComponentAlarm, or NULL
, if no alarm exists.
[transfer full][nullable][element-type ECalComponentAlarm]
Since: 3.34