/usr/include/evolution-data-server/libedata-book/e-book-backend-sqlitedb.h is in libedata-book1.2-dev 3.10.4-0ubuntu1.6.
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 | /*-*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/* e-book-backend-sqlitedb.h
*
* Copyright (C) 1999-2008 Novell, Inc. (www.novell.com)
* Copyright (C) 2012 Intel Corporation
*
* Authors:
* Chenthill Palanisamy <pchenthill@novell.com>
* Tristan Van Berkom <tristanvb@openismus.com>
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU Lesser General Public
* License as published by the Free Software Foundation.
*
* This program 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 program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
#if !defined (__LIBEDATA_BOOK_H_INSIDE__) && !defined (LIBEDATA_BOOK_COMPILATION)
#error "Only <libedata-book/libedata-book.h> should be included directly."
#endif
#ifndef E_BOOK_BACKEND_SQLITEDB_H
#define E_BOOK_BACKEND_SQLITEDB_H
#include <libebook-contacts/libebook-contacts.h>
/* Standard GObject macros */
#define E_TYPE_BOOK_BACKEND_SQLITEDB \
(e_book_backend_sqlitedb_get_type ())
#define E_BOOK_BACKEND_SQLITEDB(obj) \
(G_TYPE_CHECK_INSTANCE_CAST \
((obj), E_TYPE_BOOK_BACKEND_SQLITEDB, EBookBackendSqliteDB))
#define E_BOOK_BACKEND_SQLITEDB_CLASS(cls) \
(G_TYPE_CHECK_CLASS_CAST \
((cls), E_TYPE_BOOK_BACKEND_SQLITEDB, EBookBackendSqliteDBClass))
#define E_IS_BOOK_BACKEND_SQLITEDB(obj) \
(G_TYPE_CHECK_INSTANCE_TYPE \
((obj), E_TYPE_BOOK_BACKEND_SQLITEDB))
#define E_IS_BOOK_BACKEND_SQLITEDB_CLASS(cls) \
(G_TYPE_CHECK_CLASS_TYPE \
((cls), E_TYPE_BOOK_BACKEND_SQLITEDB))
#define E_BOOK_BACKEND_SQLITEDB_GET_CLASS(obj) \
(G_TYPE_INSTANCE_GET_CLASS \
((obj), E_TYPE_BOOK_BACKEND_SQLITEDB, EBookBackendSqliteDBClass))
/**
* E_BOOK_SDB_ERROR:
*
* Error domain for #EBookBackendSqliteDB operations.
*
* Since: 3.8
**/
#define E_BOOK_SDB_ERROR (e_book_backend_sqlitedb_error_quark ())
G_BEGIN_DECLS
typedef struct _EBookBackendSqliteDB EBookBackendSqliteDB;
typedef struct _EBookBackendSqliteDBClass EBookBackendSqliteDBClass;
typedef struct _EBookBackendSqliteDBPrivate EBookBackendSqliteDBPrivate;
/**
* EBookSDBError:
* @E_BOOK_SDB_ERROR_CONSTRAINT: The error occurred due to an explicit constraint
* @E_BOOK_SDB_ERROR_CONTACT_NOT_FOUND: A contact was not found by UID (this is different
* from a query that returns no results, which is not an error).
* @E_BOOK_SDB_ERROR_OTHER: Another error occurred
* @E_BOOK_SDB_ERROR_NOT_SUPPORTED: A query was not supported
* @E_BOOK_SDB_ERROR_INVALID_QUERY: A query was invalid. This can happen if the sexp could not be parsed
* or if a phone number query contained non-phonenumber input.
*
* Defines the types of possible errors reported by the #EBookBackendSqliteDB
*/
typedef enum {
E_BOOK_SDB_ERROR_CONSTRAINT,
E_BOOK_SDB_ERROR_CONTACT_NOT_FOUND,
E_BOOK_SDB_ERROR_OTHER,
E_BOOK_SDB_ERROR_NOT_SUPPORTED,
E_BOOK_SDB_ERROR_INVALID_QUERY
} EBookSDBError;
/**
* EBookBackendSqliteDB:
*
* Contains only private data that should be read and manipulated using the
* functions below.
*
* Since: 3.2
**/
struct _EBookBackendSqliteDB {
GObject parent;
EBookBackendSqliteDBPrivate *priv;
};
struct _EBookBackendSqliteDBClass {
GObjectClass parent_class;
};
/**
* EbSdbSearchData:
*
* FIXME: Document me.
*
* Since: 3.2
**/
typedef struct {
gchar *vcard;
gchar *uid;
gchar *bdata;
} EbSdbSearchData;
GType e_book_backend_sqlitedb_get_type
(void) G_GNUC_CONST;
GQuark e_book_backend_sqlitedb_error_quark
(void);
EBookBackendSqliteDB *
e_book_backend_sqlitedb_new (const gchar *path,
const gchar *emailid,
const gchar *folderid,
const gchar *folder_name,
gboolean store_vcard,
GError **error);
EBookBackendSqliteDB *
e_book_backend_sqlitedb_new_full
(const gchar *path,
const gchar *emailid,
const gchar *folderid,
const gchar *folder_name,
gboolean store_vcard,
ESourceBackendSummarySetup *setup,
GError **error);
gboolean e_book_backend_sqlitedb_lock_updates
(EBookBackendSqliteDB *ebsdb,
GError **error);
gboolean e_book_backend_sqlitedb_unlock_updates
(EBookBackendSqliteDB *ebsdb,
gboolean do_commit,
GError **error);
gboolean e_book_backend_sqlitedb_new_contact
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
EContact *contact,
gboolean replace_existing,
GError **error);
gboolean e_book_backend_sqlitedb_new_contacts
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
GSList *contacts,
gboolean replace_existing,
GError **error);
gboolean e_book_backend_sqlitedb_remove_contact
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
const gchar *uid,
GError **error);
gboolean e_book_backend_sqlitedb_remove_contacts
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
GSList *uids,
GError **error);
gboolean e_book_backend_sqlitedb_has_contact
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
const gchar *uid,
gboolean *partial_content,
GError **error);
EContact * e_book_backend_sqlitedb_get_contact
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
const gchar *uid,
GHashTable *fields_of_interest,
gboolean *with_all_required_fields,
GError **error);
gchar * e_book_backend_sqlitedb_get_vcard_string
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
const gchar *uid,
GHashTable *fields_of_interest,
gboolean *with_all_required_fields,
GError **error);
GSList * e_book_backend_sqlitedb_search (EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
const gchar *sexp,
GHashTable *fields_of_interest,
gboolean *searched,
gboolean *with_all_required_fields,
GError **error);
GSList * e_book_backend_sqlitedb_search_uids
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
const gchar *sexp,
gboolean *searched,
GError **error);
GHashTable * e_book_backend_sqlitedb_get_uids_and_rev
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
GError **error);
gboolean e_book_backend_sqlitedb_get_is_populated
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
GError **error);
gboolean e_book_backend_sqlitedb_set_is_populated
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
gboolean populated,
GError **error);
gboolean e_book_backend_sqlitedb_get_revision
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
gchar **revision_out,
GError **error);
gboolean e_book_backend_sqlitedb_set_revision
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
const gchar *revision,
GError **error);
gchar * e_book_backend_sqlitedb_get_sync_data
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
GError **error);
gboolean e_book_backend_sqlitedb_set_sync_data
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
const gchar *sync_data,
GError **error);
gchar * e_book_backend_sqlitedb_get_key_value
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
const gchar *key,
GError **error);
gboolean e_book_backend_sqlitedb_set_key_value
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
const gchar *key,
const gchar *value,
GError **error);
gchar * e_book_backend_sqlitedb_get_contact_bdata
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
const gchar *uid,
GError **error);
gboolean e_book_backend_sqlitedb_set_contact_bdata
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
const gchar *uid,
const gchar *value,
GError **error);
gboolean e_book_backend_sqlitedb_get_has_partial_content
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
GError **error);
gboolean e_book_backend_sqlitedb_set_has_partial_content
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
gboolean partial_content,
GError **error);
GSList * e_book_backend_sqlitedb_get_partially_cached_ids
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
GError **error);
gboolean e_book_backend_sqlitedb_delete_addressbook
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
GError **error);
gboolean e_book_backend_sqlitedb_remove (EBookBackendSqliteDB *ebsdb,
GError **error);
void e_book_backend_sqlitedb_search_data_free
(EbSdbSearchData *s_data);
gboolean e_book_backend_sqlitedb_check_summary_query
(EBookBackendSqliteDB *ebsdb,
const gchar *query,
gboolean *with_list_attrs);
gboolean e_book_backend_sqlitedb_check_summary_fields
(EBookBackendSqliteDB *ebsdb,
GHashTable *fields_of_interest);
#ifndef EDS_DISABLE_DEPRECATED
gboolean e_book_backend_sqlitedb_is_summary_query
(const gchar *query);
gboolean e_book_backend_sqlitedb_is_summary_fields
(GHashTable *fields_of_interest);
gboolean e_book_backend_sqlitedb_add_contact
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
EContact *contact,
gboolean partial_content,
GError **error);
gboolean e_book_backend_sqlitedb_add_contacts
(EBookBackendSqliteDB *ebsdb,
const gchar *folderid,
GSList *contacts,
gboolean partial_content,
GError **error);
#endif
G_END_DECLS
#endif /* E_BOOK_BACKEND_SQLITEDB_H */
|