Update of /cvsroot/mahogany/M/include
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv29655/include
Modified Files:
MimePartVirtual.h
Log Message:
implemented full support for showing PGP/MIME encoded messages (i.e. arbitrary MIME
structure inside encoded part)
Index: MimePartVirtual.h
===================================================================
RCS file: /cvsroot/mahogany/M/include/MimePartVirtual.h,v
retrieving revision 1.1
retrieving revision 1.2
diff -b -u -2 -r1.1 -r1.2
--- MimePartVirtual.h 13 Jul 2004 21:58:41 -0000 1.1
+++ MimePartVirtual.h 16 Jul 2004 23:43:55 -0000 1.2
@@ -33,4 +33,20 @@
*/
MimePartVirtual(const String& msgText);
+
+ /**
+ Construct a nested MIME part.
+
+ Note that pStart points directly into the (grand) parents buffer.
+
+ @param body structure of this part
+ @param parent the parent MIME part
+ @param nPart the 1-based number of this part among its siblings
+ @param pHeader start of the header
+ */
+ MimePartVirtual(struct mail_bodystruct *body,
+ MimePartVirtual *parent,
+ size_t nPart,
+ const char *pHeader);
+
virtual ~MimePartVirtual();
@@ -39,12 +55,25 @@
private:
- // the entire text of the message
+ // create all nested subparts
+ void CreateSubParts();
+
+ // get pointer to the start of the body (+2 is for "\r\n")
+ const char *GetBodyStart() const { return m_pStart + m_lenHeader + 2; }
+
+
+ // the entire text of the message, only non empty for the top level part
String m_msgText;
- // message envelope (base class already ahs the body)
- struct mail_envelope *m_env;
+ // pointer to the start of headers of this part
+ const char *m_pStart;
- // the length of the header (at the start of m_msgText)
+ // the length of the header (offset of the start of the body at m_pStart)
size_t m_lenHeader;
+
+ // the length of (just) the body
+ size_t m_lenBody;
+
+ // message envelope (base class already has the body)
+ struct mail_envelope *m_env;
};
-------------------------------------------------------
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=4721&alloc_id=10040&op=click
_______________________________________________
Mahogany-cvsupdates mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mahogany-cvsupdates