Mail Accounts

Mail Accounts

Synopsis

#include <e-util/e-account-utils.h>

EAccountList *	     e_get_account_list                  (void);
EAccount *	         e_get_default_account               (void);
void                e_set_default_account               (EAccount *account);
EAccount *	         e_get_account_by_name               (const gchar *name);
EAccount *	         e_get_account_by_uid                (const gchar *uid);
EAccount *	         e_get_account_by_source_url         (const gchar *source_url);
EAccount *	         e_get_account_by_transport_url      (const gchar *transport_url);
EAccount *	         e_get_any_enabled_account           (void);
EAccountService *   e_get_default_transport             (void);
GList *		           e_get_subscribable_accounts         (CamelSession *session);

Description

Details

e_get_account_list ()

EAccountList *	     e_get_account_list                  (void);

Returns the global EAccountList.

Returns :

the global EAccountList

e_get_default_account ()

EAccount *	         e_get_default_account               (void);

Returns the EAccount marked as the default mail account.

Returns :

the default EAccount

e_set_default_account ()

void                e_set_default_account               (EAccount *account);

Marks account as the default mail account.

account :

an EAccount

e_get_account_by_name ()

EAccount *	         e_get_account_by_name               (const gchar *name);

Returns the EAccount with the given name, or NULL if no such account exists.

name :

a mail account name

Returns :

an EAccount having the given account name, or NULL

e_get_account_by_uid ()

EAccount *	         e_get_account_by_uid                (const gchar *uid);

Returns the EAccount with the given unique ID, or NULL if no such account exists.

uid :

a mail account UID

Returns :

an EAccount having the given unique ID, or NULL

e_get_account_by_source_url ()

EAccount *	         e_get_account_by_source_url         (const gchar *source_url);

Returns the EAccount with the given source URL, or NULL if no such account exists.

source_url :

a source URL

Returns :

an EAccount having the given source URL, or NULL

e_get_account_by_transport_url ()

EAccount *	         e_get_account_by_transport_url      (const gchar *transport_url);

Returns the EAccount with the given transport URL, or NULL if no such account exists.

transport_url :

a transport URL

Returns :

an EAccount having the given transport URL, or NULL

e_get_any_enabled_account ()

EAccount *	         e_get_any_enabled_account           (void);

Returns the default mail account if it's enabled, otherwise the first enabled mail account in the global EAccountList, or finally NULL if all mail accounts are disabled or none exist.

Returns :

an enabled EAccount, or NULL if there are none

e_get_default_transport ()

EAccountService *   e_get_default_transport             (void);

Returns transport information for the default account if it's enabled and has transport information, or else from the first enabled mail account in the global EAccountList that has transport information, or finally NULL if no transport information could be found.

Returns :

an EAccountService with transport info, or NULL

e_get_subscribable_accounts ()

GList *		           e_get_subscribable_accounts         (CamelSession *session);

Returns a list of enabled accounts that support folder subscriptions. The EAccount objects are not referenced, but the list itself should be should be freed with g_list_free().

session :

a CamelSession

Returns :

a list of EAccount objects