mailtransport
servertest.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef MAILTRANSPORT_SERVERTEST_H
00021 #define MAILTRANSPORT_SERVERTEST_H
00022
00023 #include <mailtransport/mailtransport_export.h>
00024 #include <mailtransport/transport.h>
00025
00026 #include <QtGui/QWidget>
00027 #include <QtCore/QHash>
00028
00029 class QProgressBar;
00030
00031 namespace MailTransport
00032 {
00033
00034 class ServerTestPrivate;
00035
00041 class MAILTRANSPORT_EXPORT ServerTest : public QWidget
00042 {
00043 Q_OBJECT
00044 Q_PROPERTY( QString server READ server WRITE setServer )
00045 Q_PROPERTY( QString protocol READ protocol WRITE setProtocol )
00046 Q_PROPERTY( QProgressBar* progressBar READ progressBar WRITE setProgressBar )
00047
00048 public:
00053 ServerTest( QWidget* parent = 0 );
00054
00058 ~ServerTest();
00059
00063 void setServer( const QString& server );
00064
00068 QString server();
00069
00080 void setFakeHostname( const QString& fakeHostname );
00081
00085 QString fakeHostname();
00086
00092 void setProgressBar( QProgressBar* pb );
00093
00097 QProgressBar* progressBar();
00098
00103 void setProtocol( const QString& protocol );
00104
00108 QString protocol();
00109
00113 void start();
00114
00120 QList< int > normalProtocols();
00121
00127 QList< int > secureProtocols();
00128
00129 Q_SIGNALS:
00134 void finished( QList< int > );
00135
00136 private:
00137 Q_DECLARE_PRIVATE(ServerTest)
00138 ServerTestPrivate *const d;
00139
00140 Q_PRIVATE_SLOT(d, void slotNormalPossible() )
00141 Q_PRIVATE_SLOT(d, void slotSslPossible())
00142 Q_PRIVATE_SLOT(d, void slotReadNormal( const QString& text ))
00143 Q_PRIVATE_SLOT(d, void slotReadSecure( const QString& text ))
00144 Q_PRIVATE_SLOT(d, void slotNormalNotPossible())
00145 Q_PRIVATE_SLOT(d, void slotSslNotPossible())
00146 Q_PRIVATE_SLOT(d, void slotUpdateProgress())
00147 };
00148
00149 }
00150
00151 #endif