kmail
KMail::AccountManager Class Reference
The account manager is responsible for creating accounts of various types via the factory method create() and for keeping track of them. More...
#include <accountmanager.h>
Inherits QObject.
Public Slots | |
void | singleCheckMail (KMAccount *, bool interactive=true) |
void | singleInvalidateIMAPFolders (KMAccount *) |
void | intCheckMail (int, bool interactive=true) |
void | processNextCheck (bool newMail) |
void | addToTotalNewMailCount (const TQMap< TQString, int > &newInFolder) |
Signals | |
void | checkedMail (bool newMail, bool interactive, const TQMap< TQString, int > &newInFolder) |
void | accountRemoved (KMAccount *account) |
void | accountAdded (KMAccount *account) |
Public Member Functions | |
AccountManager () | |
void | readConfig (void) |
void | writeConfig (bool withSync=true) |
KMAccount * | create (const TQString &type, const TQString &name=TQString::null, uint id=0) |
void | add (KMAccount *account) |
KMAccount * | findByName (const TQString &name) const |
KMAccount * | find (const uint id) const |
bool | remove (KMAccount *) |
const KMAccount * | first () const |
KMAccount * | first () |
const KMAccount * | next () const |
KMAccount * | next () |
void | checkMail (bool interactive=true) |
void | invalidateIMAPFolders () |
TQStringList | getAccounts () const |
void | cancelMailCheck () |
void | readPasswords () |
Friends | |
class | ::KMAccount |
Detailed Description
The account manager is responsible for creating accounts of various types via the factory method create() and for keeping track of them.Definition at line 35 of file accountmanager.h.
Constructor & Destructor Documentation
AccountManager::AccountManager | ( | ) |
Initializes the account manager.
readConfig() needs to be called in order to fill it with persisted account information from the config file.
Definition at line 34 of file accountmanager.cpp.
Member Function Documentation
void AccountManager::readConfig | ( | void | ) |
void AccountManager::writeConfig | ( | bool | withSync = true |
) |
KMAccount * AccountManager::create | ( | const TQString & | type, | |
const TQString & | name = TQString::null , |
|||
uint | id = 0 | |||
) |
Create a new account of given type with given name.
Currently the types "local" for local mail folders and "pop" are supported.
Definition at line 237 of file accountmanager.cpp.
void AccountManager::add | ( | KMAccount * | account | ) |
KMAccount * AccountManager::findByName | ( | const TQString & | name | ) | const |
Find account by name.
Returns 0 if account does not exist. Search is done case sensitive.
Definition at line 284 of file accountmanager.cpp.
KMAccount * AccountManager::find | ( | const uint | id | ) | const |
Find account by id.
Returns 0 if account does not exist.
Definition at line 296 of file accountmanager.cpp.
bool AccountManager::remove | ( | KMAccount * | acct | ) |
Physically remove account.
Also deletes the given account object ! Returns FALSE and does nothing if the account cannot be removed.
Definition at line 328 of file accountmanager.cpp.
const KMAccount* KMail::AccountManager::first | ( | ) | const [inline] |
const KMAccount* KMail::AccountManager::next | ( | ) | const [inline] |
void AccountManager::checkMail | ( | bool | interactive = true |
) |
void AccountManager::invalidateIMAPFolders | ( | ) |
void AccountManager::cancelMailCheck | ( | ) |
void AccountManager::readPasswords | ( | ) |
void AccountManager::addToTotalNewMailCount | ( | const TQMap< TQString, int > & | newInFolder | ) | [slot] |
this slot increases the count of new mails to show a total number after checking in multiple accounts.
Definition at line 395 of file accountmanager.cpp.
void KMail::AccountManager::checkedMail | ( | bool | newMail, | |
bool | interactive, | |||
const TQMap< TQString, int > & | newInFolder | |||
) | [signal] |
Emitted if new mail has been collected.
- Parameters:
-
newMail true if there was new mail interactive true if the mail check was initiated by the user newInFolder number of new messages for each folder
void KMail::AccountManager::accountRemoved | ( | KMAccount * | account | ) | [signal] |
emitted when an account is removed
void KMail::AccountManager::accountAdded | ( | KMAccount * | account | ) | [signal] |
emitted when an account is added
The documentation for this class was generated from the following files: