Annotation of libwww/Library/src/HTMulpar.html, revision 2.4
2.1 frystyk 1: <HTML>
2: <HEAD>
2.3 frystyk 3: <TITLE>W3C Reference Library libwww MIME MULTIPART STREAM</TITLE>
2.4 ! frystyk 4: <!-- Changed by: Henrik Frystyk Nielsen, 23-Mar-1996 -->
2.1 frystyk 5: </HEAD>
6: <BODY>
7:
8: <H1>MIME Multipart Stream Definition</H1>
9:
10: <PRE>
11: /*
12: ** (c) COPYRIGHT MIT 1995.
13: ** Please first read the full copyright statement in the file COPYRIGH.
14: */
15: </PRE>
16:
17: This module is a part of the <A
18: HREF="http://www.w3.org/pub/WWW/Library/"> W3C Reference Library</A>.
19:
20: <PRE>
21: #ifndef HTMULPAR_H
22: #define HTMULPAR_H
23:
24: #include "HTStream.h"
25: #include "HTList.h"
26: </PRE>
27:
28: The MIME multipart stream is used to parse MIME multipart messages. It
29: works a bit like a structured stream in that it has some methods to
30: begin and end MIME body just as a structured stream has methods for
31: beginning and ending tags. <P>
32:
33: The <CODE>HTMultipart stream</CODE> is a subclass of a <A
34: HREF="HTStream.html">Generic Stream Object</A>. As always, we don't
35: have classes in basic C so we have to do this by hand! <P>
36:
37: <PRE>
38: typedef struct _HTMultipart HTMultipart;
39:
40: typedef struct _HTMultipartClass {
41:
42: char * name;
43:
44: int (*flush) (HTMultipart * me);
45:
46: int (*_free) (HTMultipart * me);
47:
48: int (*abort) (HTMultipart * me, HTList * errorlist);
49:
50: int (*put_character)(HTMultipart * me, char ch);
51:
2.2 frystyk 52: int (*put_string) (HTMultipart * me, const char * str);
2.1 frystyk 53:
2.2 frystyk 54: int (*put_block) (HTMultipart * me, const char * str, int len);
2.1 frystyk 55: </PRE>
56:
57: See the <A HREF="HTStream.html">Generic Stream Definition</A> for an
58: explanation of these methods. Note that they all have a
59: <CODE>HTMultipart</CODE> object a the parameter, not a generic
60: stream. This is to avoid <EM>incompatible pointer</EM> warnings
61:
62: <PRE>
2.2 frystyk 63: int (*begin_part) (HTMultipart * me, const char * boundary);
2.1 frystyk 64:
65: int (*end_part) (HTMultipart * me);
66:
2.2 frystyk 67: int (*preamble) (HTMultipart * me, const char * pre);
2.1 frystyk 68:
2.2 frystyk 69: int (*epilogue) (HTMultipart * me, const char * epi);
2.1 frystyk 70:
71: } HTMultipartClass;
72:
73: #endif
74: </PRE>
2.4 ! frystyk 75:
! 76: <HR>
! 77: <ADDRESS>
! 78: @(#) $Id: Date Author State $
! 79: </ADDRESS>
2.1 frystyk 80: </BODY>
81: </HTML>
Webmaster