Diffstat (limited to 'noncore/net/mail/libmailwrapper/pop3wrapper.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/net/mail/libmailwrapper/pop3wrapper.h | 43 |
1 files changed, 3 insertions, 40 deletions
diff --git a/noncore/net/mail/libmailwrapper/pop3wrapper.h b/noncore/net/mail/libmailwrapper/pop3wrapper.h index 75d70f8..b738cca 100644 --- a/noncore/net/mail/libmailwrapper/pop3wrapper.h +++ b/noncore/net/mail/libmailwrapper/pop3wrapper.h | |||
@@ -1,26 +1,12 @@ | |||
1 | #ifndef __POP3WRAPPER | 1 | #ifndef __POP3WRAPPER |
2 | #define __POP3WRAPPER | 2 | #define __POP3WRAPPER |
3 | 3 | ||
4 | #include <libetpan/clist.h> | ||
5 | #include "mailwrapper.h" | 4 | #include "mailwrapper.h" |
6 | #include "abstractmail.h" | 5 | #include "genericwrapper.h" |
7 | #include <qmap.h> | ||
8 | #include <qstring.h> | 6 | #include <qstring.h> |
9 | 7 | ||
10 | class RecMail; | ||
11 | class RecBody; | ||
12 | class encodedString; | ||
13 | struct mailpop3; | ||
14 | struct mailmessage; | ||
15 | struct mailmime; | ||
16 | struct mailmime_mechanism; | ||
17 | struct mailimf_mailbox_list; | ||
18 | struct mailimf_mailbox; | ||
19 | struct mailimf_date_time; | ||
20 | struct mailimf_group; | ||
21 | struct mailimf_address_list; | ||
22 | 8 | ||
23 | class POP3wrapper : public AbstractMail | 9 | class POP3wrapper : public Genericwrapper |
24 | { | 10 | { |
25 | Q_OBJECT | 11 | Q_OBJECT |
26 | 12 | ||
@@ -30,40 +16,17 @@ public: | |||
30 | /* mailbox will be ignored */ | 16 | /* mailbox will be ignored */ |
31 | virtual void listMessages(const QString & mailbox, QList<RecMail> &target ); | 17 | virtual void listMessages(const QString & mailbox, QList<RecMail> &target ); |
32 | virtual QList<Folder>* listFolders(); | 18 | virtual QList<Folder>* listFolders(); |
33 | virtual QString fetchTextPart(const RecMail&mail,const RecPart&part); | ||
34 | virtual encodedString* fetchDecodedPart(const RecMail&mail,const RecPart&part); | ||
35 | virtual encodedString* fetchRawPart(const RecMail&mail,const RecPart&part); | ||
36 | 19 | ||
37 | virtual void deleteMail(const RecMail&mail); | 20 | virtual void deleteMail(const RecMail&mail); |
38 | virtual void answeredMail(const RecMail&mail); | 21 | virtual void answeredMail(const RecMail&mail); |
39 | 22 | ||
40 | RecBody fetchBody( const RecMail &mail ); | 23 | virtual RecBody fetchBody( const RecMail &mail ); |
41 | static void pop3_progress( size_t current, size_t maximum ); | 24 | static void pop3_progress( size_t current, size_t maximum ); |
42 | 25 | ||
43 | protected: | 26 | protected: |
44 | void login(); | 27 | void login(); |
45 | void logout(); | 28 | void logout(); |
46 | 29 | ||
47 | RecMail *parseHeader( const char *header ); | ||
48 | RecBody parseMail( char *message ); | ||
49 | QString parseMailboxList( mailimf_mailbox_list *list ); | ||
50 | QString parseMailbox( mailimf_mailbox *box ); | ||
51 | QString parseGroup( mailimf_group *group ); | ||
52 | QString parseAddressList( mailimf_address_list *list ); | ||
53 | QString parseDateTime( mailimf_date_time *date ); | ||
54 | |||
55 | void cleanUpCache(); | ||
56 | |||
57 | void traverseBody(RecBody&target,mailmessage*message,mailmime*mime,unsigned int current_rek=0); | ||
58 | static void fillSingleBody(RecPart&target,mailmessage*message,mailmime*mime); | ||
59 | static void fillParameters(RecPart&target,clist*parameters); | ||
60 | static QString POP3wrapper::getencoding(mailmime_mechanism*aEnc); | ||
61 | |||
62 | POP3account *account; | ||
63 | mailpop3 *m_pop3; | ||
64 | QString msgTempName; | ||
65 | unsigned int last_msg_id; | ||
66 | QMap<QString,encodedString*> bodyCache; | ||
67 | }; | 30 | }; |
68 | 31 | ||
69 | #endif | 32 | #endif |