MIMEDirVCardEMail

Name

MIMEDirVCardEMail -- 

Synopsis


#include <mimedir/mimedir-vcard-email.h>


enum        MIMEDirVCardEMailType;

struct      MIMEDirVCardEMail;

MIMEDirVCardEMail* mimedir_vcard_email_new  (void);
MIMEDirVCardEMail* mimedir_vcard_email_new_from_attribute
                                            (MIMEDirAttribute *attribute,
                                             GError **error);
gboolean    mimedir_vcard_email_set_from_attribute
                                            (MIMEDirVCardEMail *email,
                                             MIMEDirAttribute *attribute,
                                             GError **error);
MIMEDirAttribute* mimedir_vcard_email_save_to_attribute
                                            (MIMEDirVCardEMail *email);
gchar*      mimedir_vcard_email_get_as_string
                                            (MIMEDirVCardEMail *email);
gchar*      mimedir_vcard_email_get_type_string
                                            (MIMEDirVCardEMail *email);


Description

Details

enum MIMEDirVCardEMailType

typedef enum {
	MIMEDIR_VCARD_EMAIL_TYPE_UNKNOWN,
	MIMEDIR_VCARD_EMAIL_TYPE_INTERNET,
	MIMEDIR_VCARD_EMAIL_TYPE_X400
} MIMEDirVCardEMailType;

Type of e-mail address.

MIMEDIR_VCARD_EMAIL_TYPE_UNKNOWNThe e-mail address type is unknown or unsupported.
MIMEDIR_VCARD_EMAIL_TYPE_INTERNETAn Internet e-mail address.
MIMEDIR_VCARD_EMAIL_TYPE_X400An X.400 address.


struct MIMEDirVCardEMail

struct MIMEDirVCardEMail
{
	GObject parent;

	MIMEDirVCardEMailPriv *priv;
};

The MIMEDirVCardEMail struct contains private data only, and should be accessed using the functions below.


mimedir_vcard_email_new ()

MIMEDirVCardEMail* mimedir_vcard_email_new  (void);

Create a new MIMEDirVCardEMail object.

Returns : the MIMEDirVCardEMail object


mimedir_vcard_email_new_from_attribute ()

MIMEDirVCardEMail* mimedir_vcard_email_new_from_attribute
                                            (MIMEDirAttribute *attribute,
                                             GError **error);

Creates a new MIMEDirVCardEMail object, initializing it with data taken from the attribute object.

attribute : the object to take data from
error : location to store the error occuring, or NULL to ignore
Returns : the MIMEDirVCardEMail object


mimedir_vcard_email_set_from_attribute ()

gboolean    mimedir_vcard_email_set_from_attribute
                                            (MIMEDirVCardEMail *email,
                                             MIMEDirAttribute *attribute,
                                             GError **error);

Initializes the email object to data taken from the attribute object. It is save to use this function, even if the object has been initialized before. All old data will be lost in this case.

email : the object to manipulate
attribute : the object to take data from
error : location to store the error occuring, or NULL to ignore
Returns : success indicator


mimedir_vcard_email_save_to_attribute ()

MIMEDirAttribute* mimedir_vcard_email_save_to_attribute
                                            (MIMEDirVCardEMail *email);

Returns a new attribute that describes the e-mail address.

email : an e-mail object
Returns : a new attribute


mimedir_vcard_email_get_as_string ()

gchar*      mimedir_vcard_email_get_as_string
                                            (MIMEDirVCardEMail *email);

Returns the email address as a human-readable string. The returned string should be freed with g_free().

email : the email object
Returns : the email address as human-readable string


mimedir_vcard_email_get_type_string ()

gchar*      mimedir_vcard_email_get_type_string
                                            (MIMEDirVCardEMail *email);

Returns the type(s) of the email as a human-readable string. It should be freed with g_free().

email : the email object
Returns : the type as human-readable string