![]() | ![]() | ![]() | Evolution API Reference: libebook, the Addressbook Library | ![]() |
---|
EContact — An individual contact in an addressbook.
struct EContact; enum EContactField; struct EContactName; struct EContactPhoto; struct EContactAddress; struct EContactDate; EContact* e_contact_new (void); EContact* e_contact_new_from_vcard (constchar *vcard); EContact* e_contact_duplicate (EContact *contact);gpointer e_contact_get (EContact *contact, EContactField field_id); constgpointer e_contact_get_const (EContact *contact, EContactField field_id);void e_contact_set (EContact *contact, EContactField field_id,gpointer value); EContactDate* e_contact_date_new (void); EContactDate* e_contact_date_from_string (constchar *str);char * e_contact_date_to_string (EContactDate *dt);gboolean e_contact_date_equal (EContactDate *dt1, EContactDate *dt2); EContactName* e_contact_name_new (void);char * e_contact_name_to_string (const EContactName *name); EContactName* e_contact_name_from_string (constchar *name_str); EContactName* e_contact_name_copy (EContactName *name);void e_contact_date_free (EContactDate *date);void e_contact_name_free (EContactName *name);void e_contact_photo_free (EContactPhoto *photo);void e_contact_address_free (EContactAddress *address); constchar * e_contact_field_name (EContactField field_id); constchar * e_contact_pretty_name (EContactField field_id); EContactField e_contact_field_id (constchar *field_name);
GObject +----EVCard +----EContact
"address"gpointer : Read / Write "address-home" EContactAddress : Read / Write "address-label-home"gchararray : Read / Write "address-label-other"gchararray : Read / Write "address-label-work"gchararray : Read / Write "address-other" EContactAddress : Read / Write "address-work" EContactAddress : Read / Write "anniversary" EContactDate : Read / Write "assistant"gchararray : Read / Write "assistant-phone"gchararray : Read / Write "birth-date" EContactDate : Read / Write "blog-url"gchararray : Read / Write "business-fax"gchararray : Read / Write "business-phone"gchararray : Read / Write "business-phone-2"gchararray : Read / Write "callback-phone"gchararray : Read / Write "caluri"gchararray : Read / Write "car-phone"gchararray : Read / Write "categories"gchararray : Read / Write "company-phone"gchararray : Read / Write "email"gpointer : Read / Write "email-1"gchararray : Read / Write "email-2"gchararray : Read / Write "email-3"gchararray : Read / Write "family-name"gchararray : Read / Write "fburl"gchararray : Read / Write "file-as"gchararray : Read / Write "full-name"gpointer : Read / Write "given-name"gchararray : Read / Write "home-fax"gchararray : Read / Write "home-phone"gchararray : Read / Write "home-phone-2"gchararray : Read / Write "homepage-url"gchararray : Read / Write "icscalendar"gchararray : Read / Write "id"gchararray : Read / Write "im-aim"gpointer : Read / Write "im-icq"gpointer : Read / Write "im-jabber"gpointer : Read / Write "im-msn"gpointer : Read / Write "im-yahoo"gpointer : Read / Write "isdn-phone"gchararray : Read / Write "list"gboolean : Read / Write "list-show-addresses"gboolean : Read / Write "logo" EContactPhoto : Read / Write "mailer"gchararray : Read / Write "manager"gchararray : Read / Write "mobile-phone"gchararray : Read / Write "name" EContactName : Read / Write "name-or-org"gchararray : Read "nickname"gchararray : Read / Write "note"gchararray : Read / Write "office"gchararray : Read / Write "org"gchararray : Read / Write "org-unit"gchararray : Read / Write "other-fax"gchararray : Read / Write "other-phone"gchararray : Read / Write "pager"gchararray : Read / Write "photo" EContactPhoto : Read / Write "primary-phone"gchararray : Read / Write "radio"gchararray : Read / Write "role"gchararray : Read / Write "spouse"gchararray : Read / Write "telex"gchararray : Read / Write "title"gchararray : Read / Write "tty"gchararray : Read / Write "wants-html"gboolean : Read / Write "x509Cert"EContactCert : Read / Write
A convenient way of accessing the contact information in EVCard objects.
typedef enum { E_CONTACT_UID = 1, /* string field */ E_CONTACT_FILE_AS, /* string field */ /* Name fields */ E_CONTACT_FULL_NAME, /* string field */ E_CONTACT_GIVEN_NAME, /* synthetic string field */ E_CONTACT_FAMILY_NAME, /* synthetic string field */ E_CONTACT_NICKNAME, /* string field */ /* Email fields */ E_CONTACT_EMAIL_1, /* synthetic string field */ E_CONTACT_EMAIL_2, /* synthetic string field */ E_CONTACT_EMAIL_3, /* synthetic string field */ E_CONTACT_MAILER, /* string field */ /* Address Labels */ E_CONTACT_ADDRESS_LABEL_HOME, /* synthetic string field */ E_CONTACT_ADDRESS_LABEL_WORK, /* synthetic string field */ E_CONTACT_ADDRESS_LABEL_OTHER, /* synthetic string field */ /* Phone fields */ E_CONTACT_PHONE_ASSISTANT, E_CONTACT_PHONE_BUSINESS, E_CONTACT_PHONE_BUSINESS_2, E_CONTACT_PHONE_BUSINESS_FAX, E_CONTACT_PHONE_CALLBACK, E_CONTACT_PHONE_CAR, E_CONTACT_PHONE_COMPANY, E_CONTACT_PHONE_HOME, E_CONTACT_PHONE_HOME_2, E_CONTACT_PHONE_HOME_FAX, E_CONTACT_PHONE_ISDN, E_CONTACT_PHONE_MOBILE, E_CONTACT_PHONE_OTHER, E_CONTACT_PHONE_OTHER_FAX, E_CONTACT_PHONE_PAGER, E_CONTACT_PHONE_PRIMARY, E_CONTACT_PHONE_RADIO, E_CONTACT_PHONE_TELEX, E_CONTACT_PHONE_TTYTDD, /* Organizational fields */ E_CONTACT_ORG, /* string field */ E_CONTACT_ORG_UNIT, /* string field */ E_CONTACT_OFFICE, /* string field */ E_CONTACT_TITLE, /* string field */ E_CONTACT_ROLE, /* string field */ E_CONTACT_MANAGER, /* string field */ E_CONTACT_ASSISTANT, /* string field */ /* Web fields */ E_CONTACT_HOMEPAGE_URL, /* string field */ E_CONTACT_BLOG_URL, /* string field */ /* Contact categories */ E_CONTACT_CATEGORIES, /* string field */ /* Collaboration fields */ E_CONTACT_CALENDAR_URI, /* string field */ E_CONTACT_FREEBUSY_URL, /* string field */ E_CONTACT_ICS_CALENDAR, /* string field */ /* misc fields */ E_CONTACT_SPOUSE, /* string field */ E_CONTACT_NOTE, /* string field */ /* fields used for describing contact lists. a contact list is just a contact with _IS_LIST set to true. the members are listed in the _EMAIL field. */ E_CONTACT_IS_LIST, /* boolean field */ E_CONTACT_LIST_SHOW_ADDRESSES, /* boolean field */ /* Instant Messaging fields */ E_CONTACT_IM_AIM, /* Multi-valued */ E_CONTACT_IM_JABBER, /* Multi-valued */ E_CONTACT_IM_YAHOO, /* Multi-valued */ E_CONTACT_IM_MSN, /* Multi-valued */ E_CONTACT_IM_ICQ, /* Multi-valued */ /* Address fields */ E_CONTACT_ADDRESS, /* Multi-valued structured (EContactAddress) */ E_CONTACT_ADDRESS_HOME, /* synthetic structured field (EContactAddress) */ E_CONTACT_ADDRESS_WORK, /* synthetic structured field (EContactAddress) */ E_CONTACT_ADDRESS_OTHER, /* synthetic structured field (EContactAddress) */ E_CONTACT_CATEGORY_LIST, /* multi-valued */ /* Photo/Logo */ E_CONTACT_PHOTO, /* structured field (EContactPhoto) */ E_CONTACT_LOGO, /* structured field (EContactPhoto) */ E_CONTACT_NAME, /* structured field (EContactName) */ E_CONTACT_EMAIL, /* Multi-valued */ E_CONTACT_WANTS_HTML, /* boolean field */ E_CONTACT_BIRTH_DATE, /* structured field (EContactDate) */ E_CONTACT_ANNIVERSARY, /* structured field (EContactDate) */ /* Security Fields */ E_CONTACT_X509_CERT, /* structured field (EContactCert) */ /* Convenience field for getting a name from the contact. Returns the first one of [File-As, Full Name, Org, Email1] to be set */ E_CONTACT_NAME_OR_ORG, E_CONTACT_FIELD_LAST, /* useful constants */ E_CONTACT_LAST_SIMPLE_STRING = E_CONTACT_NOTE, E_CONTACT_FIRST_PHONE_ID = E_CONTACT_PHONE_ASSISTANT, E_CONTACT_LAST_PHONE_ID = E_CONTACT_PHONE_TTYTDD, E_CONTACT_FIRST_EMAIL_ID = E_CONTACT_EMAIL_1, E_CONTACT_LAST_EMAIL_ID = E_CONTACT_EMAIL_3, E_CONTACT_FIRST_ADDRESS_ID = E_CONTACT_ADDRESS_HOME, E_CONTACT_LAST_ADDRESS_ID = E_CONTACT_ADDRESS_OTHER, E_CONTACT_FIRST_LABEL_ID = E_CONTACT_ADDRESS_LABEL_HOME, E_CONTACT_LAST_LABEL_ID = E_CONTACT_ADDRESS_LABEL_OTHER } EContactField;
struct EContactName { char *family; char *given; char *additional; char *prefixes; char *suffixes; };
struct EContactAddress { char *address_format; /* the two letter country code that determines the format/meaning of the following fields */ char *po; char *ext; char *street; char *locality; char *region; char *code; char *country; };
EContact* e_contact_new_from_vcard (constchar *vcard);
vcard : | |
Returns : |
gpointer e_contact_get (EContact *contact, EContactField field_id);
contact : | |
field_id : | |
Returns : |
constgpointer e_contact_get_const (EContact *contact, EContactField field_id);
contact : | |
field_id : | |
Returns : |
void e_contact_set (EContact *contact, EContactField field_id,gpointer value);
contact : | |
field_id : | |
value : |
EContactDate* e_contact_date_from_string (constchar *str);
str : | |
Returns : |
gboolean e_contact_date_equal (EContactDate *dt1, EContactDate *dt2);
dt1 : | |
dt2 : | |
Returns : |
char * e_contact_name_to_string (const EContactName *name);
name : | |
Returns : |
EContactName* e_contact_name_from_string (constchar *name_str);
name_str : | |
Returns : |
constchar * e_contact_field_name (EContactField field_id);
field_id : | |
Returns : |
constchar * e_contact_pretty_name (EContactField field_id);
field_id : | |
Returns : |
EContactField e_contact_field_id (constchar *field_name);
field_name : | |
Returns : |
"address" ( | |
"address-home" (EContactAddress : Read / Write) | |
"address-label-home" ( | |
"address-label-other" ( | |
"address-label-work" ( | |
"address-other" (EContactAddress : Read / Write) | |
"address-work" (EContactAddress : Read / Write) | |
"anniversary" (EContactDate : Read / Write) | |
"assistant" ( | |
"assistant-phone" ( | |
"birth-date" (EContactDate : Read / Write) | |
"blog-url" ( | |
"business-fax" ( | |
"business-phone" ( | |
"business-phone-2" ( | |
"callback-phone" ( | |
"caluri" ( | |
"car-phone" ( | |
"categories" ( | |
"company-phone" ( | |
"email" ( | |
"email-1" ( | |
"email-2" ( | |
"email-3" ( | |
"family-name" ( | |
"fburl" ( | |
"file-as" ( | |
"full-name" ( | |
"given-name" ( | |
"home-fax" ( | |
"home-phone" ( | |
"home-phone-2" ( | |
"homepage-url" ( | |
"icscalendar" ( | |
"id" ( | |
"im-aim" ( | |
"im-icq" ( | |
"im-jabber" ( | |
"im-msn" ( | |
"im-yahoo" ( | |
"isdn-phone" ( | |
"list" ( | |
"list-show-addresses" ( | |
"logo" (EContactPhoto : Read / Write) | |
"mailer" ( | |
"manager" ( | |
"mobile-phone" ( | |
"name" (EContactName : Read / Write) | |
"name-or-org" ( | |
"nickname" ( | |
"note" ( | |
"office" ( | |
"org" ( | |
"org-unit" ( | |
"other-fax" ( | |
"other-phone" ( | |
"pager" ( | |
"photo" (EContactPhoto : Read / Write) | |
"primary-phone" ( | |
"radio" ( | |
"role" ( | |
"spouse" ( | |
"telex" ( | |
"title" ( | |
"tty" ( | |
"wants-html" ( | |
"x509Cert" ( |
<< e-book-query | EVCard >> |