/usr/include/evolution-data-server/libedata-cal/e-cal-cache.h is in libedata-cal1.2-dev 3.28.1-1ubuntu1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/*
* Copyright (C) 2016 Red Hat, Inc. (www.redhat.com)
*
* This library is free software: you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation.
*
* This library is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License
* for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with this library. If not, see <http://www.gnu.org/licenses/>.
*/
#if !defined (__LIBEDATA_CAL_H_INSIDE__) && !defined (LIBEDATA_CAL_COMPILATION)
#error "Only <libedata-cal/libedata-cal.h> should be included directly."
#endif
#ifndef E_CAL_CACHE_H
#define E_CAL_CACHE_H
#include <libebackend/libebackend.h>
#include <libecal/libecal.h>
/* Standard GObject macros */
#define E_TYPE_CAL_CACHE \
(e_cal_cache_get_type ())
#define E_CAL_CACHE(obj) \
(G_TYPE_CHECK_INSTANCE_CAST \
((obj), E_TYPE_CAL_CACHE, ECalCache))
#define E_CAL_CACHE_CLASS(cls) \
(G_TYPE_CHECK_CLASS_CAST \
((cls), E_TYPE_CAL_CACHE, ECalCacheClass))
#define E_IS_CAL_CACHE(obj) \
(G_TYPE_CHECK_INSTANCE_TYPE \
((obj), E_TYPE_CAL_CACHE))
#define E_IS_CAL_CACHE_CLASS(cls) \
(G_TYPE_CHECK_CLASS_TYPE \
((cls), E_TYPE_CAL_CACHE))
#define E_CAL_CACHE_GET_CLASS(obj) \
(G_TYPE_INSTANCE_GET_CLASS \
((obj), E_TYPE_CAL_CACHE, ECalCacheClass))
G_BEGIN_DECLS
typedef struct _ECalCache ECalCache;
typedef struct _ECalCacheClass ECalCacheClass;
typedef struct _ECalCachePrivate ECalCachePrivate;
/**
* ECalCacheOfflineChange:
* @uid: UID of the component
* @rid: Recurrence-ID of the component
* @revision: stored revision of the component
* @object: the component itself, as iCalalendar string
* @state: an #EOfflineState of the component
*
* Holds the information about offline change for one component.
*
* Since: 3.26
**/
typedef struct {
gchar *uid;
gchar *rid;
gchar *revision;
gchar *object;
EOfflineState state;
} ECalCacheOfflineChange;
#define E_TYPE_CAL_CACHE_OFFLINE_CHANGE (e_cal_cache_offline_change_get_type ())
GType e_cal_cache_offline_change_get_type
(void) G_GNUC_CONST;
ECalCacheOfflineChange *
e_cal_cache_offline_change_new (const gchar *uid,
const gchar *rid,
const gchar *revision,
const gchar *object,
EOfflineState state);
ECalCacheOfflineChange *
e_cal_cache_offline_change_copy (const ECalCacheOfflineChange *change);
void e_cal_cache_offline_change_free (/* ECalCacheOfflineChange */ gpointer change);
/**
* ECalCacheSearchData:
* @uid: the UID of this component
* @rid: (nullable): the Recurrence-ID of this component
* @object: the component string
* @extra: any extra data associated with the component
*
* This structure is used to represent components returned
* by the #ECalCache from various functions
* such as e_cal_cache_search().
*
* The @extra parameter will contain any data which was
* previously passed for this component in e_cal_cache_add_component()
* or set with e_cal_cache_set_component_extra().
*
* These should be freed with e_cal_cache_search_data_free().
*
* Since: 3.26
**/
typedef struct {
gchar *uid;
gchar *rid;
gchar *object;
gchar *extra;
} ECalCacheSearchData;
#define E_TYPE_CAL_CACHE_SEARCH_DATA (e_cal_cache_search_data_get_type ())
GType e_cal_cache_search_data_get_type
(void) G_GNUC_CONST;
ECalCacheSearchData *
e_cal_cache_search_data_new (const gchar *uid,
const gchar *rid,
const gchar *object,
const gchar *extra);
ECalCacheSearchData *
e_cal_cache_search_data_copy (const ECalCacheSearchData *data);
void e_cal_cache_search_data_free (/* ECalCacheSearchData * */ gpointer ptr);
/**
* ECalCacheSearchFunc:
* @cal_cache: an #ECalCache
* @uid: a unique object identifier
* @rid: (nullable): an optional Recurrence-ID of the object
* @revision: the object revision
* @object: the object itself
* @extra: extra data stored with the object
* @offline_state: objects offline state, one of #EOfflineState
* @user_data: user data, as used in e_cal_cache_search_with_callback()
*
* A callback called for each object row when using
* e_cal_cache_search_with_callback() function.
*
* Returns: %TRUE to continue, %FALSE to stop walk through.
*
* Since: 3.26
**/
typedef gboolean (* ECalCacheSearchFunc) (ECalCache *cal_cache,
const gchar *uid,
const gchar *rid,
const gchar *revision,
const gchar *object,
const gchar *extra,
EOfflineState offline_state,
gpointer user_data);
/**
* ECalCache:
*
* Contains only private data that should be read and manipulated using
* the functions below.
*
* Since: 3.26
**/
struct _ECalCache {
/*< private >*/
ECache parent;
ECalCachePrivate *priv;
};
/**
* ECalCacheClass:
*
* Class structure for the #ECalCache class.
*
* Since: 3.26
*/
struct _ECalCacheClass {
/*< private >*/
ECacheClass parent_class;
/* Signals */
gchar * (* dup_component_revision)
(ECalCache *cal_cache,
icalcomponent *icalcomp);
/* Padding for future expansion */
gpointer reserved[10];
};
GType e_cal_cache_get_type (void) G_GNUC_CONST;
ECalCache * e_cal_cache_new (const gchar *filename,
GCancellable *cancellable,
GError **error);
gchar * e_cal_cache_dup_component_revision
(ECalCache *cal_cache,
icalcomponent *icalcomp);
gboolean e_cal_cache_contains (ECalCache *cal_cache,
const gchar *uid,
const gchar *rid,
ECacheDeletedFlag deleted_flag);
gboolean e_cal_cache_put_component (ECalCache *cal_cache,
ECalComponent *component,
const gchar *extra,
ECacheOfflineFlag offline_flag,
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_put_components (ECalCache *cal_cache,
const GSList *components, /* ECalComponent * */
const GSList *extras, /* gchar * */
ECacheOfflineFlag offline_flag,
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_remove_component (ECalCache *cal_cache,
const gchar *uid,
const gchar *rid,
ECacheOfflineFlag offline_flag,
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_remove_components (ECalCache *cal_cache,
const GSList *ids, /* ECalComponentId * */
ECacheOfflineFlag offline_flag,
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_get_component (ECalCache *cal_cache,
const gchar *uid,
const gchar *rid,
ECalComponent **out_component,
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_get_component_as_string
(ECalCache *cal_cache,
const gchar *uid,
const gchar *rid,
gchar **out_icalstring,
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_set_component_extra (ECalCache *cal_cache,
const gchar *uid,
const gchar *rid,
const gchar *extra,
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_get_component_extra (ECalCache *cal_cache,
const gchar *uid,
const gchar *rid,
gchar **out_extra,
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_get_ids_with_extra (ECalCache *cal_cache,
const gchar *extra,
GSList **out_ids, /* ECalComponentId * */
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_get_components_by_uid
(ECalCache *cal_cache,
const gchar *uid,
GSList **out_components, /* ECalComponent * */
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_get_components_by_uid_as_string
(ECalCache *cal_cache,
const gchar *uid,
GSList **out_icalstrings, /* gchar * */
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_get_components_in_range
(ECalCache *cal_cache,
time_t range_start,
time_t range_end,
GSList **out_components, /* ECalComponent * */
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_get_components_in_range_as_strings
(ECalCache *cal_cache,
time_t range_start,
time_t range_end,
GSList **out_icalstrings, /* gchar * */
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_search (ECalCache *cal_cache,
const gchar *sexp,
GSList **out_data, /* ECalCacheSearchData * * */
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_search_components (ECalCache *cal_cache,
const gchar *sexp,
GSList **out_components, /* ECalComponent * */
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_search_ids (ECalCache *cal_cache,
const gchar *sexp,
GSList **out_ids, /* ECalComponentId * */
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_search_with_callback
(ECalCache *cal_cache,
const gchar *sexp,
ECalCacheSearchFunc func,
gpointer user_data,
GCancellable *cancellable,
GError **error);
GSList * e_cal_cache_get_offline_changes (ECalCache *cal_cache,
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_delete_attachments (ECalCache *cal_cache,
icalcomponent *component,
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_put_timezone (ECalCache *cal_cache,
const icaltimezone *zone,
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_get_timezone (ECalCache *cal_cache,
const gchar *tzid,
icaltimezone **out_zone,
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_dup_timezone_as_string
(ECalCache *cal_cache,
const gchar *tzid,
gchar **out_zone_string,
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_list_timezones (ECalCache *cal_cache,
GList **out_timezones,
GCancellable *cancellable,
GError **error);
gboolean e_cal_cache_remove_timezones (ECalCache *cal_cache,
GCancellable *cancellable,
GError **error);
icaltimezone * e_cal_cache_resolve_timezone_cb (const gchar *tzid,
gpointer cal_cache,
GCancellable *cancellable,
GError **error);
icaltimezone * e_cal_cache_resolve_timezone_simple_cb
(const gchar *tzid,
gpointer cal_cache);
G_END_DECLS
#endif /* E_CAL_CACHE_H */
|