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 KURL;
00027 class KAEvent;
00028 class EmailAddressList;
00029 namespace KPIM { class IdentityManager; }
00030 namespace KMime { namespace Types { struct Address; } }
00031
00032 struct KAMailData;
00033
00034
00035 class KAMail
00036 {
00037 public:
00038 static bool send(const KAEvent&, QStringList& errmsgs, bool allowNotify = true);
00039 static int checkAddress(QString& address);
00040 static int checkAttachment(QString& attachment, KURL* = 0);
00041 static bool checkAttachment(const KURL&);
00042 static QString convertAddresses(const QString& addresses, EmailAddressList&);
00043 static QString convertAttachments(const QString& attachments, QStringList& list);
00044 static KPIM::IdentityManager* identityManager();
00045 static bool identitiesExist();
00046 static uint identityUoid(const QString& identityUoidOrName);
00047 static QString controlCentreAddress();
00048 static QString getMailBody(Q_UINT32 serialNumber);
00049 static QString i18n_NeedFromEmailAddress();
00050 static QString i18n_sent_mail();
00051
00052 private:
00053 static KPIM::IdentityManager* mIdentityManager;
00054 static QString sendKMail(const KAMailData&);
00055 static QString initHeaders(const KAMailData&, bool dateId);
00056 static QString appendBodyAttachments(QString& message, const KAEvent&);
00057 static QString addToKMailFolder(const KAMailData&, const char* folder, bool checkKmailRunning);
00058 static bool callKMail(const QByteArray& callData, const QCString& iface, const QCString& function, const QCString& funcType);
00059 static QString convertAddress(KMime::Types::Address, EmailAddressList&);
00060 static void notifyQueued(const KAEvent&);
00061 static char* base64Encode(const char* in, QIODevice::Offset size, QIODevice::Offset& outSize);
00062 static QStringList errors(const QString& error = QString::null, bool sendfail = true);
00063 };
00064
00065 #endif // KAMAIL_H
|