Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

SMTPwrapper Class Reference

#include </home/clem/local/src/opie/noncore/net/mail/libmailwrapper/smtpwrapper.h>

Inheritance diagram for SMTPwrapper:

Inheritance graph
[legend]
Collaboration diagram for SMTPwrapper:

Collaboration graph
[legend]
List of all members.

Signals

void queuedMails (int)

Public Member Functions

 SMTPwrapper (SMTPaccount *aSmtp)
virtual ~SMTPwrapper ()
void sendMail (const Opie::Core::OSmartPointer< Mail > &mail, bool later=false)
bool flushOutbox ()

Static Public Attributes

static progressMailSendsendProgress = 0

Protected Slots

void emitQCop (int queued)

Protected Member Functions

void connect_server ()
void disc_server ()
int start_smtp_tls ()
void smtpSend (mailmime *mail, bool later)
int smtpSend (char *from, clist *rcpts, const char *data, size_t size)
void storeMail (mailmime *mail, const QString &box)
int sendQueuedMail (AbstractMail *wrap, const Opie::Core::OSmartPointer< RecMail > &which)
void storeFailedMail (const char *data, unsigned int size, const char *failuremessage)

Static Protected Member Functions

static void storeMail (const char *mail, size_t length, const QString &box)
static QString mailsmtpError (int err)
static void progress (size_t current, size_t maximum)

Protected Attributes

mailsmtp * m_smtp
SMTPaccountm_SmtpAccount
int m_queuedMail

Constructor & Destructor Documentation

SMTPwrapper::SMTPwrapper SMTPaccount aSmtp  ) 
 

Definition at line 20 of file smtpwrapper.cpp.

References emitQCop(), m_queuedMail, m_smtp, m_SmtpAccount, queuedMails(), Config::readNumEntry(), and Config::setGroup().

SMTPwrapper::~SMTPwrapper  )  [virtual]
 

Definition at line 32 of file smtpwrapper.cpp.

References disc_server().


Member Function Documentation

void SMTPwrapper::connect_server  )  [protected]
 

Definition at line 180 of file smtpwrapper.cpp.

References Account::ConnectionType(), SMTPaccount::getLogin(), LoginDialog::getPassword(), Account::getPassword(), Account::getPort(), Account::getServer(), LoginDialog::getUser(), Account::getUser(), m_smtp, m_SmtpAccount, mailsmtpError(), NULL, odebug, oendl, progress(), server, start_smtp_tls(), tr, and true.

Referenced by smtpSend().

void SMTPwrapper::disc_server  )  [protected]
 

Definition at line 281 of file smtpwrapper.cpp.

References m_smtp.

Referenced by ~SMTPwrapper().

void SMTPwrapper::emitQCop int  queued  )  [protected, slot]
 

Definition at line 37 of file smtpwrapper.cpp.

Referenced by SMTPwrapper().

bool SMTPwrapper::flushOutbox  ) 
 

Definition at line 379 of file smtpwrapper.cpp.

References QValueList< T >::append(), QValueList< T >::begin(), QValueList< T >::count(), AbstractMail::defaultLocalfolder(), AbstractMail::deleteMails(), SMTPaccount::getLogin(), LoginDialog::getPassword(), Account::getPassword(), LoginDialog::getUser(), Account::getUser(), AbstractMail::getWrapper(), AbstractMail::listMessages(), m_queuedMail, m_SmtpAccount, NULL, odebug, oendl, queuedMails(), QValueList< T >::remove(), sendProgress, sendQueuedMail(), progressMailSend::setCurrentMails(), Config::setGroup(), progressMailSend::setMaxMails(), Account::setPassword(), Account::setUser(), tr, true, and Config::writeEntry().

Referenced by OpieMail::slotSendQueued().

QString SMTPwrapper::mailsmtpError int  err  )  [static, protected]
 

Definition at line 42 of file smtpwrapper.cpp.

References tr.

Referenced by connect_server(), and smtpSend().

void SMTPwrapper::progress size_t  current,
size_t  maximum
[static, protected]
 

Definition at line 86 of file smtpwrapper.cpp.

References qApp, and progressMailSend::setSingleMail().

Referenced by connect_server().

void SMTPwrapper::queuedMails int   )  [signal]
 

Referenced by flushOutbox(), smtpSend(), and SMTPwrapper().

void SMTPwrapper::sendMail const Opie::Core::OSmartPointer< Mail > &  mail,
bool  later = false
 

Definition at line 317 of file smtpwrapper.cpp.

References Generatemail::createMimeMail(), NULL, odebug, oendl, sendProgress, progressMailSend::setMaxMails(), and smtpSend().

Referenced by ComposeMail::accept().

int SMTPwrapper::sendQueuedMail AbstractMail wrap,
const Opie::Core::OSmartPointer< RecMail > &  which
[protected]
 

Referenced by flushOutbox().

int SMTPwrapper::smtpSend char *  from,
clist *  rcpts,
const char *  data,
size_t  size
[protected]
 

Definition at line 290 of file smtpwrapper.cpp.

References connect_server(), m_smtp, mailsmtpError(), odebug, oendl, storeFailedMail(), storeMail(), and tr.

void SMTPwrapper::smtpSend mailmime *  mail,
bool  later
[protected]
 

Definition at line 103 of file smtpwrapper.cpp.

References Generatemail::createRcptList(), data, Generatemail::getFrom(), m_queuedMail, odebug, oendl, queuedMails(), Config::setGroup(), size, storeMail(), and Config::writeEntry().

Referenced by sendMail().

int SMTPwrapper::start_smtp_tls  )  [protected]
 

Definition at line 157 of file smtpwrapper.cpp.

References low, and m_smtp.

Referenced by connect_server().

void SMTPwrapper::storeFailedMail const char *  data,
unsigned int  size,
const char *  failuremessage
[protected]
 

Definition at line 146 of file smtpwrapper.cpp.

References storeMail(), and tr.

Referenced by smtpSend().

void SMTPwrapper::storeMail mailmime *  mail,
const QString box
[protected]
 

void SMTPwrapper::storeMail const char *  mail,
size_t  length,
const QString box
[static, protected]
 

Definition at line 93 of file smtpwrapper.cpp.

References AbstractMail::createMbox(), AbstractMail::defaultLocalfolder(), AbstractMail::getWrapper(), and AbstractMail::storeMessage().

Referenced by smtpSend(), and storeFailedMail().


Member Data Documentation

int SMTPwrapper::m_queuedMail [protected]
 

Definition at line 56 of file smtpwrapper.h.

Referenced by flushOutbox(), smtpSend(), and SMTPwrapper().

mailsmtp* SMTPwrapper::m_smtp [protected]
 

Definition at line 35 of file smtpwrapper.h.

Referenced by connect_server(), disc_server(), smtpSend(), SMTPwrapper(), and start_smtp_tls().

SMTPaccount* SMTPwrapper::m_SmtpAccount [protected]
 

Definition at line 36 of file smtpwrapper.h.

Referenced by connect_server(), flushOutbox(), and SMTPwrapper().

progressMailSend * SMTPwrapper::sendProgress = 0 [static]
 

Definition at line 18 of file smtpwrapper.cpp.

Referenced by flushOutbox(), and sendMail().


The documentation for this class was generated from the following files:
Generated on Sat Nov 5 17:52:13 2005 for OPIE by  doxygen 1.4.2