kalarm
kamail.h00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef KAMAIL_H
00022 #define KAMAIL_H
00023
00024 #include <qstring.h>
00025 #include <qstringlist.h>
00026 class KAEvent;
00027 class EmailAddressList;
00028 namespace KPIM { class IdentityManager; }
00029 namespace KMime { namespace Types { struct Address; } }
00030
00031 struct KAMailData;
00032
00033
00034 class KAMail
00035 {
00036 public:
00037 static bool send(const KAEvent&, QStringList& errmsgs, bool allowNotify = true);
00038 static int checkAddress(QString& address);
00039 static int checkAttachment(QString& attachment, KURL* = 0);
00040 static bool checkAttachment(const KURL&);
00041 static QString convertAddresses(const QString& addresses, EmailAddressList&);
00042 static QString convertAttachments(const QString& attachments, QStringList& list);
00043 static KPIM::IdentityManager* identityManager();
00044 static bool identitiesExist();
00045 static QString controlCentreAddress();
00046 static QString getMailBody(Q_UINT32 serialNumber);
00047 static QString i18n_NeedFromEmailAddress();
00048 static QString i18n_sent_mail();
00049
00050 private:
00051 static KPIM::IdentityManager* mIdentityManager;
00052 static QString sendKMail(const KAMailData&);
00053 static QString initHeaders(const KAMailData&, bool dateId);
00054 static QString appendBodyAttachments(QString& message, const KAEvent&);
00055 static QString addToKMailFolder(const KAMailData&, const char* folder, bool checkKmailRunning);
00056 static bool callKMail(const QByteArray& callData, const QCString& iface, const QCString& function, const QCString& funcType);
00057 static QString convertAddress(KMime::Types::Address, EmailAddressList&);
00058 static void notifyQueued(const KAEvent&);
00059 static char* base64Encode(const char* in, QIODevice::Offset size, QIODevice::Offset& outSize);
00060 static QStringList errors(const QString& error = QString::null, bool sendfail = true);
00061 };
00062
00063 #endif // KAMAIL_H
|