diff --git a/src/SmtpMime b/src/SmtpMime index 940996b..7b0c576 100644 --- a/src/SmtpMime +++ b/src/SmtpMime @@ -27,5 +27,6 @@ #include "mimetext.h" #include "mimeinlinefile.h" #include "mimefile.h" +#include "mimebytearrayattachment.h" #endif // SMTPMIME_H diff --git a/src/mimebytearrayattachment.cpp b/src/mimebytearrayattachment.cpp new file mode 100644 index 0000000..60ec22e --- /dev/null +++ b/src/mimebytearrayattachment.cpp @@ -0,0 +1,13 @@ +#include "mimebytearrayattachment.h" + +MimeByteArrayAttachment::MimeByteArrayAttachment(const QString& name, const QByteArray &content) : + MimePart() +{ + this->cType = "application/octet-stream"; + this->cEncoding = Base64; + this->cName = name, + this->content = content; +} + +MimeByteArrayAttachment::~MimeByteArrayAttachment() {} + diff --git a/src/mimebytearrayattachment.h b/src/mimebytearrayattachment.h new file mode 100644 index 0000000..bd63ad3 --- /dev/null +++ b/src/mimebytearrayattachment.h @@ -0,0 +1,20 @@ +#ifndef MIMEBYTEARRAYATTACHMENT_H +#define MIMEBYTEARRAYATTACHMENT_H + +#include "smtpmime_global.h" +#include "mimepart.h" + +class SMTP_MIME_EXPORT MimeByteArrayAttachment : public MimePart +{ +public: + /* [1] Constructors and Destructors */ + + MimeByteArrayAttachment(const QString& name, const QByteArray &content); + ~MimeByteArrayAttachment(); + + /* [1] --- */ + + +}; + +#endif // MIMEBYTEARRAYATTACHMENT_H diff --git a/src/smtpclient.cpp b/src/smtpclient.cpp index a3b326c..a0e8190 100644 --- a/src/smtpclient.cpp +++ b/src/smtpclient.cpp @@ -30,8 +30,6 @@ SmtpClient::SmtpClient(const QString & host, int port, ConnectionType connection state(UnconnectedState), name("localhost"), authMethod(AuthPlain), - connectionTimeout(5000), - responseTimeout(5000), isReadyConnected(false), isAuthenticated(false), isMailSent(false) diff --git a/src/smtpclient.h b/src/smtpclient.h index a7892e3..19cb27c 100644 --- a/src/smtpclient.h +++ b/src/smtpclient.h @@ -172,9 +172,6 @@ protected: AuthMethod authMethod; bool clearUserDataAfterLogin; - int connectionTimeout; - int responseTimeout; - QString responseText; QString tempResponse; int responseCode;