|
a/src/internfile/mh_mail.h |
|
b/src/internfile/mh_mail.h |
|
... |
|
... |
18 |
#define _MAIL_H_INCLUDED_
|
18 |
#define _MAIL_H_INCLUDED_
|
19 |
/* @(#$Id: mh_mail.h,v 1.13 2008-10-04 14:26:59 dockes Exp $ (C) 2004 J.F.Dockes */
|
19 |
/* @(#$Id: mh_mail.h,v 1.13 2008-10-04 14:26:59 dockes Exp $ (C) 2004 J.F.Dockes */
|
20 |
|
20 |
|
21 |
#include <sstream>
|
21 |
#include <sstream>
|
22 |
#include <vector>
|
22 |
#include <vector>
|
|
|
23 |
#include <map>
|
23 |
using std::vector;
|
24 |
using std::vector;
|
|
|
25 |
using std::map;
|
24 |
|
26 |
|
25 |
#include "mimehandler.h"
|
27 |
#include "mimehandler.h"
|
26 |
|
28 |
|
27 |
namespace Binc {
|
29 |
namespace Binc {
|
28 |
class MimeDocument;
|
30 |
class MimeDocument;
|
|
... |
|
... |
36 |
* for maildir files). This has to keep state while parsing a mail folder
|
38 |
* for maildir files). This has to keep state while parsing a mail folder
|
37 |
* file.
|
39 |
* file.
|
38 |
*/
|
40 |
*/
|
39 |
class MimeHandlerMail : public RecollFilter {
|
41 |
class MimeHandlerMail : public RecollFilter {
|
40 |
public:
|
42 |
public:
|
41 |
MimeHandlerMail(const string &mt)
|
43 |
MimeHandlerMail(const string &mt);
|
42 |
: RecollFilter(mt), m_bincdoc(0), m_fd(-1), m_stream(0), m_idx(-1)
|
|
|
43 |
{}
|
|
|
44 |
virtual ~MimeHandlerMail();
|
44 |
virtual ~MimeHandlerMail();
|
45 |
virtual bool set_document_file(const string& file_path);
|
45 |
virtual bool set_document_file(const string& file_path);
|
46 |
virtual bool set_document_string(const string& data);
|
46 |
virtual bool set_document_string(const string& data);
|
47 |
virtual bool is_data_input_ok(DataInput input) const {
|
47 |
virtual bool is_data_input_ok(DataInput input) const {
|
48 |
if (input == DOCUMENT_FILE_NAME || input == DOCUMENT_STRING)
|
48 |
if (input == DOCUMENT_FILE_NAME || input == DOCUMENT_STRING)
|
|
... |
|
... |
67 |
// Start of actual text (after the reprinted headers. This is for
|
67 |
// Start of actual text (after the reprinted headers. This is for
|
68 |
// generating a semi-meaningful "abstract")
|
68 |
// generating a semi-meaningful "abstract")
|
69 |
string::size_type m_startoftext;
|
69 |
string::size_type m_startoftext;
|
70 |
string m_subject;
|
70 |
string m_subject;
|
71 |
vector<MHMailAttach *> m_attachments;
|
71 |
vector<MHMailAttach *> m_attachments;
|
|
|
72 |
// Additional headers to be process as per config + field name translation
|
|
|
73 |
map<string,string> m_addProcdHdrs;
|
72 |
};
|
74 |
};
|
73 |
|
75 |
|
74 |
class MHMailAttach {
|
76 |
class MHMailAttach {
|
75 |
public:
|
77 |
public:
|
76 |
string m_contentType;
|
78 |
string m_contentType;
|