Diffstat (limited to 'noncore/net/mailit/smtpclient.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/net/mailit/smtpclient.h | 58 |
1 files changed, 29 insertions, 29 deletions
diff --git a/noncore/net/mailit/smtpclient.h b/noncore/net/mailit/smtpclient.h index ca65af4..45c0703 100644 --- a/noncore/net/mailit/smtpclient.h +++ b/noncore/net/mailit/smtpclient.h @@ -9,67 +9,67 @@ ** packaging of this file. ** ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. ** ** See http://www.trolltech.com/gpl/ for GPL licensing information. ** ** Contact info@trolltech.com if any conditions of this licensing are ** not clear to you. ** **********************************************************************/ #ifndef SmtpClient_H #define SmtpClient_H //#include <stdio.h> #include <qsocket.h> #include <qstring.h> #include <qobject.h> #include <qtextstream.h> #include <qstringlist.h> #include <qlist.h> struct RawEmail { - QString from; - QString subject; - QStringList to; - QString body; + QString from; + QString subject; + QStringList to; + QString body; }; class SmtpClient: public QObject { - Q_OBJECT - + Q_OBJECT + public: - SmtpClient(); - ~SmtpClient(); - void newConnection(QString target, int port); - void addMail(QString from, QString subject, QStringList to, QString body); + SmtpClient(); + ~SmtpClient(); + void newConnection(const QString &target, int port); + void addMail(const QString &from, const QString &subject, const QStringList &to, const QString &body); signals: - void errorOccurred(int); - void updateStatus(const QString &); - void mailSent(); - + void errorOccurred(int); + void updateStatus(const QString &); + void mailSent(); + public slots: - void errorHandling(int); + void errorHandling(int); protected slots: - void connectionEstablished(); - void incomingData(); - + void connectionEstablished(); + void incomingData(); + private: - QSocket *socket; - QTextStream *stream; - enum transferStatus - { - Init, From, Recv, MRcv, Data, Body, Quit, Done - }; - int status; - QList<RawEmail> mailList; - RawEmail *mailPtr; - bool sending; - QStringList::Iterator it; + QSocket *socket; + QTextStream *stream; + enum transferStatus + { + Init, From, Recv, MRcv, Data, Body, Quit, Done + }; + int status; + QList<RawEmail> mailList; + RawEmail *mailPtr; + bool sending; + QStringList::Iterator it; }; #endif |