author | Michael Krelin <hacker@klever.net> | 2007-07-04 11:23:42 (UTC) |
---|---|---|
committer | Michael Krelin <hacker@klever.net> | 2007-07-04 11:23:42 (UTC) |
commit | a08aff328d4393031d5ba7d622c2b05705a89d73 (patch) (unidiff) | |
tree | 8ee90d686081c52e7c69b5ce946e9b1a7d690001 /kmicromail/libmailwrapper/genericwrapper.h | |
parent | 11edc920afe4f274c0964436633aa632c8288a40 (diff) | |
download | kdepimpi-p1.zip kdepimpi-p1.tar.gz kdepimpi-p1.tar.bz2 |
initial public commit of qt4 portp1
Diffstat (limited to 'kmicromail/libmailwrapper/genericwrapper.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | kmicromail/libmailwrapper/genericwrapper.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/kmicromail/libmailwrapper/genericwrapper.h b/kmicromail/libmailwrapper/genericwrapper.h index c35a6da..a50161d 100644 --- a/kmicromail/libmailwrapper/genericwrapper.h +++ b/kmicromail/libmailwrapper/genericwrapper.h | |||
@@ -1,68 +1,70 @@ | |||
1 | // CHANGED 2004-09-31 Lutz Rogowski | 1 | // CHANGED 2004-09-31 Lutz Rogowski |
2 | #ifndef __GENERIC_WRAPPER_H | 2 | #ifndef __GENERIC_WRAPPER_H |
3 | #define __GENERIC_WRAPPER_H | 3 | #define __GENERIC_WRAPPER_H |
4 | 4 | ||
5 | #include "abstractmail.h" | 5 | #include "abstractmail.h" |
6 | #include <qmap.h> | 6 | #include <qmap.h> |
7 | #include <qstring.h> | 7 | #include <qstring.h> |
8 | //Added by qt3to4: | ||
9 | #include <Q3ValueList> | ||
8 | #include <libetpan/clist.h> | 10 | #include <libetpan/clist.h> |
9 | 11 | ||
10 | class RecMail; | 12 | class RecMail; |
11 | class RecBody; | 13 | class RecBody; |
12 | class encodedString; | 14 | class encodedString; |
13 | struct mailpop3; | 15 | struct mailpop3; |
14 | struct mailmessage; | 16 | struct mailmessage; |
15 | struct mailmime; | 17 | struct mailmime; |
16 | struct mailmime_mechanism; | 18 | struct mailmime_mechanism; |
17 | struct mailimf_mailbox_list; | 19 | struct mailimf_mailbox_list; |
18 | struct mailimf_mailbox; | 20 | struct mailimf_mailbox; |
19 | struct mailimf_date_time; | 21 | struct mailimf_date_time; |
20 | struct mailimf_group; | 22 | struct mailimf_group; |
21 | struct mailimf_address_list; | 23 | struct mailimf_address_list; |
22 | struct mailsession; | 24 | struct mailsession; |
23 | struct mailstorage; | 25 | struct mailstorage; |
24 | struct mailfolder; | 26 | struct mailfolder; |
25 | struct mailimf_in_reply_to; | 27 | struct mailimf_in_reply_to; |
26 | 28 | ||
27 | /* this class hold just the funs shared between | 29 | /* this class hold just the funs shared between |
28 | * mbox and pop3 (later mh, too) mail access. | 30 | * mbox and pop3 (later mh, too) mail access. |
29 | * it is not desigend to make a instance of it! | 31 | * it is not desigend to make a instance of it! |
30 | */ | 32 | */ |
31 | class Genericwrapper : public AbstractMail | 33 | class Genericwrapper : public AbstractMail |
32 | { | 34 | { |
33 | Q_OBJECT | 35 | Q_OBJECT |
34 | public: | 36 | public: |
35 | Genericwrapper(); | 37 | Genericwrapper(); |
36 | virtual ~Genericwrapper(); | 38 | virtual ~Genericwrapper(); |
37 | 39 | ||
38 | virtual encodedString* fetchDecodedPart(const RecMailP&mail,const RecPartP&part); | 40 | virtual encodedString* fetchDecodedPart(const RecMailP&mail,const RecPartP&part); |
39 | virtual encodedString* fetchRawPart(const RecMailP&mail,const RecPartP&part); | 41 | virtual encodedString* fetchRawPart(const RecMailP&mail,const RecPartP&part); |
40 | virtual QString fetchTextPart(const RecMailP&mail,const RecPartP&part); | 42 | virtual QString fetchTextPart(const RecMailP&mail,const RecPartP&part); |
41 | virtual void cleanMimeCache(); | 43 | virtual void cleanMimeCache(); |
42 | virtual int deleteMbox(const Opie::Core::OSmartPointer<Folder>&){return 1;} | 44 | virtual int deleteMbox(const Opie::Core::OSmartPointer<Folder>&){return 1;} |
43 | virtual void logout(){}; | 45 | virtual void logout(){}; |
44 | virtual void storeMessage(const char*msg,size_t length, const QString&folder){}; | 46 | virtual void storeMessage(const char*msg,size_t length, const QString&folder){}; |
45 | static const QDateTime parseDateTime( mailimf_date_time *date ); | 47 | static const QDateTime parseDateTime( mailimf_date_time *date ); |
46 | 48 | ||
47 | protected: | 49 | protected: |
48 | RecBodyP parseMail( mailmessage * msg ); | 50 | RecBodyP parseMail( mailmessage * msg ); |
49 | QString parseMailboxList( mailimf_mailbox_list *list ); | 51 | QString parseMailboxList( mailimf_mailbox_list *list ); |
50 | QString parseMailbox( mailimf_mailbox *box ); | 52 | QString parseMailbox( mailimf_mailbox *box ); |
51 | QString parseGroup( mailimf_group *group ); | 53 | QString parseGroup( mailimf_group *group ); |
52 | QString parseAddressList( mailimf_address_list *list ); | 54 | QString parseAddressList( mailimf_address_list *list ); |
53 | 55 | ||
54 | void traverseBody(RecBodyP&target,mailmessage*message,mailmime*mime,QValueList<int>recList,unsigned int current_rek=0,int current_count=1); | 56 | void traverseBody(RecBodyP&target,mailmessage*message,mailmime*mime,Q3ValueList<int>recList,unsigned int current_rek=0,int current_count=1); |
55 | static void fillSingleBody(RecPartP&target,mailmessage*message,mailmime*mime); | 57 | static void fillSingleBody(RecPartP&target,mailmessage*message,mailmime*mime); |
56 | static void fillParameters(RecPartP&target,clist*parameters); | 58 | static void fillParameters(RecPartP&target,clist*parameters); |
57 | static QString getencoding(mailmime_mechanism*aEnc); | 59 | static QString getencoding(mailmime_mechanism*aEnc); |
58 | virtual void parseList(QValueList<Opie::Core::OSmartPointer<RecMail> > &target,mailsession*session,const QString&mailbox,bool mbox_as_to=false, int maxSizeInKb = 0); | 60 | virtual void parseList(Q3ValueList<Opie::Core::OSmartPointer<RecMail> > &target,mailsession*session,const QString&mailbox,bool mbox_as_to=false, int maxSizeInKb = 0); |
59 | QStringList parseInreplies(mailimf_in_reply_to * in_replies); | 61 | QStringList parseInreplies(mailimf_in_reply_to * in_replies); |
60 | 62 | ||
61 | QString msgTempName; | 63 | QString msgTempName; |
62 | unsigned int last_msg_id; | 64 | unsigned int last_msg_id; |
63 | QMap<QString,encodedString*> bodyCache; | 65 | QMap<QString,encodedString*> bodyCache; |
64 | mailstorage * m_storage; | 66 | mailstorage * m_storage; |
65 | mailfolder*m_folder; | 67 | mailfolder*m_folder; |
66 | }; | 68 | }; |
67 | 69 | ||
68 | #endif | 70 | #endif |