![]() |
![]() |
![]() |
Evolution-Data-Server Manual: Address Book Backend (libedata-book) | ![]() |
---|---|---|---|---|
Top | Description |
struct EBookBackendSqliteDB; EbSdbSearchData; EBookBackendSqliteDB * e_book_backend_sqlitedb_new (const gchar *path
,const gchar *email_id
,const gchar *folderid
,const gchar *folder_name
,gboolean store_vcard
,GError **error
); 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
); 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
); 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
); 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_is_summary_query (const gchar *query
); gboolean e_book_backend_sqlitedb_is_summary_fields (GHashTable *fields_of_interest
);
struct EBookBackendSqliteDB { GObject parent; EBookBackendSqliteDBPrivate *priv; };
Contains only private data that should be read and manipulated using the functions below.
Since 3.2
typedef struct { gchar *vcard; gchar *uid; gchar *bdata; } EbSdbSearchData;
FIXME: Document me.
Since 3.2
EBookBackendSqliteDB * e_book_backend_sqlitedb_new (const gchar *path
,const gchar *email_id
,const gchar *folderid
,const gchar *folder_name
,gboolean store_vcard
,GError **error
);
If the path for multiple addressbooks are same, the contacts from all addressbooks would be stored in same db in different tables.
|
location where the db would be created |
|
folder id of the address-book |
|
name of the address-book |
|
True if the vcard should be stored inside db, if FALSE only the summary fields would be stored inside db. |
Since 3.2
gboolean e_book_backend_sqlitedb_add_contact (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,EContact *contact
,gboolean partial_content
,GError **error
);
This is a convenience wrapper for e_book_backend_sqlitedb_add_contacts, which is the preferred means to add multiple contacts when possible.
|
folder id |
|
EContact to be added |
|
contact does not contain full information. Used when the backend cache's partial information for auto-completion. |
Returns : |
TRUE on success. |
Since 3.2
gboolean e_book_backend_sqlitedb_add_contacts (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,GSList *contacts
,gboolean partial_content
,GError **error
);
|
folder id |
|
list of EContacts |
|
contact does not contain full information. Used when the backend cache's partial information for auto-completion. |
Returns : |
TRUE on success. |
Since 3.2
gboolean e_book_backend_sqlitedb_remove_contact (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,const gchar *uid
,GError **error
);
FIXME: Document me.
Since 3.2
gboolean e_book_backend_sqlitedb_remove_contacts (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,GSList *uids
,GError **error
);
FIXME: Document me.
Since 3.2
gboolean e_book_backend_sqlitedb_has_contact (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,const gchar *uid
,gboolean *partial_content
,GError **error
);
FIXME: Document me.
Since 3.2
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
);
FIXME: Document me.
Since 3.2
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
);
Searches ebsdb
in the context of folderid
for uid
.
If ebsdb
is configured to store the whole vcards, the whole vcard will be returned.
Otherwise the summary cache will be searched and the virtual vcard will be built
from the summary cache.
In either case, with_all_required_fields
if specified, will be updated to reflect whether
the returned vcard string satisfies the passed 'fields_of_interest' parameter.
|
An EBookBackendSqliteDB |
|
The folder id |
|
The uid to fetch a vcard for |
|
The required fields for this vcard, or NULL to require all fields. |
|
Whether all the required fields are present in the returned vcard. [allow none][out] |
|
A location to store any error that may have occurred. |
Returns : |
The vcard string for uid or NULL if uid was not found. [transfer full]
|
Since 3.2
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
);
Searching with summary fields is always supported. Search expressions containing any other field is supported only if backend chooses to store the vcard inside the db.
Summary fields - uid, rev, nickname, given_name, family_name, file_as email_1, email_2, email_3, email_4, is_list, list_show_addresses, wants_html
If ebsdb
was incapable of returning vcards with results that satisfy
fields_of_interest
, then with_all_required_fields
will be updated to FALSE
and only uid fields will be present in the returned vcards. This can be useful
when a summary query succeeds and the returned list can be used to iterate
and fetch for full required data from another persistance.
|
search expression; use NULL or an empty string to get all stored contacts. |
|
a GHashTable containing the names of fields to return, or NULL for all. At the moment if this is non-null, the vcard will be populated with summary fields, else it would return the whole vcard if its stored in the db. [not implemented fully] |
|
Whether ebsdb was capable of searching for the provided query sexp . [allow none][out]
|
|
Whether all the required fields are present in the returned vcards. [allow none][out] |
Returns : |
List of EbSdbSearchData. |
Since 3.2
GSList * e_book_backend_sqlitedb_search_uids (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,const gchar *sexp
,gboolean *searched
,GError **error
);
FIXME: Document me.
Since 3.2
gboolean e_book_backend_sqlitedb_get_is_populated (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,GError **error
);
FIXME: Document me.
Since 3.2
gboolean e_book_backend_sqlitedb_set_is_populated (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,gboolean populated
,GError **error
);
FIXME: Document me.
Since 3.2
gchar * e_book_backend_sqlitedb_get_sync_data (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,GError **error
);
FIXME: Document me.
Since 3.2
gboolean e_book_backend_sqlitedb_set_sync_data (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,const gchar *sync_data
,GError **error
);
FIXME: Document me.
Since 3.2
gchar * e_book_backend_sqlitedb_get_key_value (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,const gchar *key
,GError **error
);
FIXME: Document me.
Since 3.2
gboolean e_book_backend_sqlitedb_set_key_value (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,const gchar *key
,const gchar *value
,GError **error
);
FIXME: Document me.
Since 3.2
gchar * e_book_backend_sqlitedb_get_contact_bdata (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,const gchar *uid
,GError **error
);
FIXME: Document me.
Since 3.2
gboolean e_book_backend_sqlitedb_set_contact_bdata (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,const gchar *uid
,const gchar *value
,GError **error
);
FIXME: Document me.
Since 3.2
gboolean e_book_backend_sqlitedb_get_has_partial_content (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,GError **error
);
Returns : |
TRUE if the vcards stored in the db were downloaded partially. It is to indicate the stored vcards does not contain the full data. |
Since 3.2
gboolean e_book_backend_sqlitedb_set_has_partial_content (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,gboolean partial_content
,GError **error
);
FIXME: Document me.
Since 3.2
GSList * e_book_backend_sqlitedb_get_partially_cached_ids (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,GError **error
);
FIXME: Document me.
Since 3.2
gboolean e_book_backend_sqlitedb_delete_addressbook (EBookBackendSqliteDB *ebsdb
,const gchar *folderid
,GError **error
);
FIXME: Document me.
Since 3.2
gboolean e_book_backend_sqlitedb_remove (EBookBackendSqliteDB *ebsdb
,GError **error
);
FIXME: Document me.
Since 3.2
void e_book_backend_sqlitedb_search_data_free
(EbSdbSearchData *s_data
);
FIXME: Document me.
Since 3.2
gboolean e_book_backend_sqlitedb_is_summary_query
(const gchar *query
);
FIXME: Document me.
Since 3.2