2 * Copyright 2007 Robert Shearman for CodeWeavers
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
23 #define DECLARE_HANDLE
(name
) typedef void *name
25 interface IMimeMessageCallback
;
26 interface IMimeEnumAddressTypes
;
27 interface IMimeMessageParts
;
28 interface IMimeMessageTree
;
30 interface IMimeEnumProperties
;
32 cpp_quote
("DEFINE_GUID(CLSID_IMimeBody, 0xfd853cdb, 0x7f86, 0x11d0, 0x82, 0x52, 0x0, 0xc0, 0x4f, 0xd8, 0x5a, 0xb4);")
33 cpp_quote
("DEFINE_GUID(CLSID_IMimeAllocator, 0xfd853cdd, 0x7f86, 0x11d0, 0x82, 0x52, 0x0, 0xc0, 0x4f, 0xd8, 0x5a, 0xb4);")
34 cpp_quote
("DEFINE_GUID(CLSID_IMimeMessage, 0xfd853ce3, 0x7f86, 0x11d0, 0x82, 0x52, 0x0, 0xc0, 0x4f, 0xd8, 0x5a, 0xb4);")
36 cpp_quote
("#define MIME_E_REG_CREATE_KEY 0x800cce01")
37 cpp_quote
("#define MIME_E_REG_QUERY_INFO 0x800cce02")
38 cpp_quote
("#define MIME_E_INVALID_ENCTYPE 0x800cce03")
39 cpp_quote
("#define MIME_E_BOUNDARY_MISMATCH 0x800cce04")
40 cpp_quote
("#define MIME_E_NOT_FOUND 0x800cce05")
41 cpp_quote
("#define MIME_E_NO_DATA 0x800cce05")
42 cpp_quote
("#define MIME_E_BUFFER_TOO_SMALL 0x800cce06")
43 cpp_quote
("#define MIME_E_INVALID_ITEM_FLAGS 0x800cce07")
44 cpp_quote
("#define MIME_E_ONE_LINE_ITEME 0x800cce08")
45 cpp_quote
("#define MIME_E_INVALID_HANDLE 0x800cce09")
46 cpp_quote
("#define MIME_E_CHARSET_TRANSLATE 0x800cce0a")
47 cpp_quote
("#define MIME_E_NOT_INITIALIZED 0x800cce0b")
49 cpp_quote
("#define MIME_E_INVALID_CHARSET_TYPE 0x800cce31")
51 cpp_quote
("#define MIME_E_INVALID_TEXT_TYPE 0x800cce38")
53 cpp_quote
("#define MIME_E_SECURITY_NOOP 0x800cceb1")
54 cpp_quote
("#define MIME_S_SECURITY_NOOP 0x000cceb1")
56 cpp_quote
("typedef enum tagMIMEPROPID {")
57 cpp_quote
(" PID_HDR_NEWSGROUP = 2,")
58 cpp_quote
(" PID_HDR_NEWSGROUPS = 3,")
59 cpp_quote
(" PID_HDR_REFS = 4,")
60 cpp_quote
(" PID_HDR_SUBJECT = 5,")
61 cpp_quote
(" PID_HDR_FROM = 6,")
62 cpp_quote
(" PID_HDR_MESSAGEID = 7,")
63 cpp_quote
(" PID_HDR_RETURNPATH = 8,")
64 cpp_quote
(" PID_HDR_RR = 9,")
65 cpp_quote
(" PID_HDR_RETRCPTO = 10,")
66 cpp_quote
(" PID_HDR_APPARTO = 11,")
67 cpp_quote
(" PID_HDR_DATE = 12,")
68 cpp_quote
(" PID_HDR_RECEIVED = 13,")
69 cpp_quote
(" PID_HDR_REPLYTO = 14,")
70 cpp_quote
(" PID_HDR_XMAILER = 15,")
71 cpp_quote
(" PID_HDR_BCC = 16,")
72 cpp_quote
(" PID_HDR_MIMEVER = 17,")
73 cpp_quote
(" PID_HDR_CNTTYPE = 18,")
74 cpp_quote
(" PID_HDR_CNTXFER = 19,")
75 cpp_quote
(" PID_HDR_CNTID = 20,")
76 cpp_quote
(" PID_HDR_CNTDESC = 21,")
77 cpp_quote
(" PID_HDR_CNTDISP = 22,")
78 cpp_quote
(" PID_HDR_CNTBASE = 23,")
79 cpp_quote
(" PID_HDR_CNTLOC = 24,")
80 cpp_quote
(" PID_HDR_TO = 25,")
81 cpp_quote
(" PID_HDR_PATH = 26,")
82 cpp_quote
(" PID_HDR_FOLLOWUPTO = 27,")
83 cpp_quote
(" PID_HDR_EXPIRES = 28,")
84 cpp_quote
(" PID_HDR_CC = 29,")
86 cpp_quote
(" PID_HDR_SENDER = 61,")
88 cpp_quote
(" PID_HDR_INREPLYTO = 77,")
89 cpp_quote
("} MIMEPROPID;")
91 cpp_quote
("#define TYPEDID_MASK ((ULONG)0xffff)")
92 cpp_quote
("#define TYPEDID_TYPE(t) ((VARTYPE)((t) & TYPEDID_MASK))")
94 cpp_quote
("#define OID_HIDE_TNEF_ATTACHMENTS (0x000e0000 | VT_BOOL)")
95 cpp_quote
("#define OID_SECURITY_TYPE (0x00180000 | VT_UI4)")
96 cpp_quote
("#define OID_SECURITY_HWND_OWNER (0x00320000 | VT_UI4)")
97 cpp_quote
("#define OID_HEADER_RELOAD_TYPE (0x00370000 | VT_UI4)")
98 cpp_quote
("#define OID_SHOW_MACBINARY (0x00390000 | VT_BOOL)")
102 uuid(e4b28371
-83b0
-11d0
-8259-00c04fd85ab4
),
107 importlib
("stdole2.tlb");
109 DECLARE_HANDLE
(HCHARSET
);
110 DECLARE_HANDLE
(HBODY
);
111 DECLARE_HANDLE
(HHEADERROW
);
113 typedef HCHARSET
*LPHCHARSET
;
114 typedef HBODY
*LPHBODY
;
115 typedef HHEADERROW
*LPHHEADERROW
;
116 typedef DWORD TYPEDID
;
117 typedef const PROPVARIANT
*LPCPROPVARIANT
;
118 typedef const BLOB
*LPCBLOB
;
120 typedef enum tagRELOADTYPE
124 RELOAD_HEADER_APPEND
,
125 RELOAD_HEADER_REPLACE
,
128 typedef enum tagMIMESAVETYPE
134 typedef enum tagCSETAPPLYTYPE
141 typedef enum tagENCODINGTYPE
159 const SHORT IET_DECODED
= IET_BINARY
;
161 const SHORT CCHMAX_HEADER_LINE
= 1000;
164 uuid(c5588349
-7f86
-11d0
-8252-00c04fd85ab4
),
167 interface IMimeInternational
: IUnknown
169 typedef [unique] IMimeInternational
*LPMIMEINTERNATIONAL
;
170 typedef DWORD CODEPAGEID
;
172 const CODEPAGEID CP_USASCII
= 1252;
173 const CODEPAGEID CP_UNICODE
= 1200;
174 const CODEPAGEID CP_JAUTODETECT
= 50932;
175 const CODEPAGEID CP_KAUTODETECT
= 50949;
176 const CODEPAGEID CP_ISO2022JPESC
= 50221;
177 const CODEPAGEID CP_ISO2022JPSIO
= 50222;
179 const SHORT CCHMAX_CSET_NAME
= 128;
180 const SHORT CCHMAX_LANG_NAME
= 128;
181 const SHORT CCHMAX_FACE_NAME
= 128;
183 typedef struct tagINETCSETINFO
185 CHAR szName
[CCHMAX_CSET_NAME
];
187 CODEPAGEID cpiWindows
;
188 CODEPAGEID cpiInternet
;
190 } INETCSETINFO
, *LPINETCSETINFO
;
192 typedef enum tagINETLANGMASK
197 ILM_HEADERCSET
= 0x08,
199 ILM_FIXEDFONT
= 0x20,
200 ILM_VARIABLEFONT
= 0x40,
203 typedef struct tagCODEPAGEINFO
206 CODEPAGEID cpiCodePage
;
207 BOOL fIsValidCodePage
;
210 CODEPAGEID cpiFamily
;
211 CHAR szName
[CCHMAX_LANG_NAME
];
212 CHAR szBodyCset
[CCHMAX_CSET_NAME
];
213 CHAR szHeaderCset
[CCHMAX_CSET_NAME
];
214 CHAR szWebCset
[CCHMAX_CSET_NAME
];
215 CHAR szFixedFont
[CCHMAX_FACE_NAME
];
216 CHAR szVariableFont
[CCHMAX_FACE_NAME
];
217 ENCODINGTYPE ietNewsDefault
;
218 ENCODINGTYPE ietMailDefault
;
220 } CODEPAGEINFO
, *LPCODEPAGEINFO
;
222 typedef struct tagRFC1522INFO
224 BOOL fRfc1522Allowed
;
227 HCHARSET hRfc1522Cset
;
228 } RFC1522INFO
, *LPRFC1522INFO
;
230 typedef enum tagCHARSETTYPE
238 HRESULT SetDefaultCharset
(
239 [in] HCHARSET hCharset
);
240 HRESULT GetDefaultCharset
(
241 [out] LPHCHARSET phCharset
);
242 HRESULT GetCodePageCharset
(
243 [in] CODEPAGEID cpiCodePage
,
244 [in] CHARSETTYPE ctCsetType
,
245 [out] LPHCHARSET phCharset
);
247 [in] LPCSTR pszCharset
,
248 [out] LPHCHARSET phCharset
);
249 HRESULT GetCharsetInfo
(
250 [in] HCHARSET hCharset
,
251 [in, out] LPINETCSETINFO pCsetInfo
);
252 HRESULT GetCodePageInfo
(
253 [in] CODEPAGEID cpiCodePage
,
254 [in, out] LPCODEPAGEINFO pCodePageInfo
);
255 HRESULT CanConvertCodePages
(
256 [in] CODEPAGEID cpiSource
,
257 [in] CODEPAGEID cpiDest
);
258 HRESULT DecodeHeader
(
259 [in] HCHARSET hCharset
,
261 [in, out] LPPROPVARIANT pDecoded
,
262 [in, out] LPRFC1522INFO pRfc1522Info
);
263 HRESULT EncodeHeader
(
264 [in] HCHARSET hCharset
,
265 [in] LPPROPVARIANT pData
,
266 [out] LPSTR
*ppszEncoded
,
267 [in, out] LPRFC1522INFO pRfc1522Info
);
268 HRESULT ConvertBuffer
(
269 [in] CODEPAGEID cpiSource
,
270 [in] CODEPAGEID cpiDest
,
272 [in, out] LPBLOB pOut
,
273 [out] ULONG
*pcbRead
);
274 HRESULT ConvertString
(
275 [in] CODEPAGEID cpiSource
,
276 [in] CODEPAGEID cpiDest
,
277 [in] LPPROPVARIANT pIn
,
278 [in, out] LPPROPVARIANT pOut
);
279 HRESULT MLANG_ConvertInetReset
(void);
280 HRESULT MLANG_ConvertInetString
(
281 [in] CODEPAGEID cpiSource
,
282 [in] CODEPAGEID cpiDest
,
284 [in] int *pnSizeOfSource
,
285 [in,out,unique] LPSTR pDestination
,
286 [in] int *pnDstSize
);
287 HRESULT Rfc1522Decode
(
288 [in] LPCSTR pszValue
,
289 [in,ref] LPSTR pszCharset
,
291 [out] LPSTR
*ppszDecoded
);
292 HRESULT Rfc1522Encode
(
293 [in] LPCSTR pszValue
,
294 [in] HCHARSET hCharset
,
295 [out] LPSTR
*ppszEncoded
);
299 uuid(c5588353
-7f86
-11d0
-8252-00c04fd85ab4
),
302 interface IMimeSecurity
: IUnknown
304 typedef [unique] IMimeSecurity
*LPMIMESECURITY
;
306 cpp_quote
("#ifdef __WINE_WINCRYPT_H")
307 cpp_quote
("typedef PCCERT_CONTEXT PCX509CERT;")
309 typedef const void *PCX509CERT
;
310 typedef void *HCERTSTORE
;
313 typedef BLOB THUMBBLOB
;
314 typedef void *HCAPICERTSTORE
;
316 cpp_quote
("#define MST_NONE 0x00000000")
317 cpp_quote
("#define MST_THIS_SIGN 0x00000001")
318 cpp_quote
("#define MST_THIS_ENCRYPT 0x00000002")
319 cpp_quote
("#define MST_BLOB_FLAG 0x00000004")
320 cpp_quote
("#define MST_THIS_BLOBSIGN (MST_BLOB_FLAG | MST_THIS_SIGN)")
321 cpp_quote
("#define MST_CHILD_SIGN 0x00000100")
322 cpp_quote
("#define MST_CHILD_ENCRYPT 0x00000200")
323 cpp_quote
("#define MST_SUBMSG_SIGN 0x00001000")
324 cpp_quote
("#define MST_SUBMSG_ENCRYPT 0x00002000")
325 cpp_quote
("#define MST_RECEIPT_REQUEST 0x00010000")
326 cpp_quote
("#define MST_CLASS_SMIME_V1 0x00000000")
327 cpp_quote
("#define MST_CLASS_PGP 0x01000000")
329 typedef enum tagCERTSTATE
332 CERTIFICATE_NOT_PRESENT
,
334 CERTIFICATE_CHAIN_TOO_LONG
,
335 CERTIFICATE_MISSING_ISSUER
,
336 CERTIFICATE_CRL_LISTED
,
337 CERTIFICATE_NOT_TRUSTED
,
344 typedef enum tagCERTNAMETYPE
351 typedef enum tagCERTDATAID
357 typedef struct tagX509CERTRESULT
362 } X509CERTRESULT
, *PX509CERTRESULT
;
363 typedef const X509CERTRESULT
*PCX509CERTRESULT
;
365 HRESULT InitNew
(void);
367 HRESULT CheckInit
(void);
369 HRESULT EncodeMessage
(
370 [in] IMimeMessageTree */
*const*/ pTree
,
374 [in] IMimeMessageTree */
*const*/ pTree
,
375 [in] HBODY hEncodeRoot
,
378 HRESULT DecodeMessage
(
379 [in] IMimeMessageTree */
*const*/ pTree
,
383 [in] IMimeMessageTree */
*const*/ pTree
,
384 [in] HBODY hDecodeRoot
,
387 HRESULT EnumCertificates
(
388 [in] HCAPICERTSTORE hc
,
390 [in] PCX509CERT pPrev
,
391 [out] PCX509CERT
*ppCert
);
393 HRESULT GetCertificateName
(
394 [in] const PCX509CERT pX509Cert
,
395 [in] const CERTNAMETYPE cn
,
396 [out] LPSTR
*ppszName
);
398 HRESULT GetMessageType
(
399 [in] const HWND hwndParent
,
400 [in] IMimeBody */
*const*/ pBody
,
401 [out] DWORD */
*const*/ pdwSecType
);
404 [in] const PCX509CERT pX509Cert
,
405 [in] const CERTDATAID dataid
,
406 [out, ref] LPPROPVARIANT pValue
);
410 uuid(fd853cd1
-7f86
-11d0
-8252-00c04fd85ab4
),
413 interface IMimeHeaderTable
: IPersistStream
415 /* FIXME: fill this in */
419 uuid(fd853cec
-7f86
-11d0
-8252-00c04fd85ab4
),
422 interface IMimePropertySchema
: IUnknown
424 typedef enum tagMIMEPROPFLAGS
429 MPF_HASPARAMS
= 0x08,
434 /* FIXME: fill this in */
438 uuid(fd853cd3
-7f86
-11d0
-8252-00c04fd85ab4
),
441 interface IMimePropertySet
: IPersistStreamInit
443 typedef [unique] IMimePropertySet
*LPMIMEPROPERTYSET
;
445 cpp_quote
("#define PDF_ENCODED 0x00000001")
446 cpp_quote
("#define PDF_NAMEINDATA 0x00000002")
447 cpp_quote
("#define PDF_HEADERFORMAT (0x00000004 | PDF_ENCODED)")
448 cpp_quote
("#define PDF_NOCOMMENTS 0x00000008")
449 cpp_quote
("#define PDF_SAVENOENCODE 0x00000010")
450 cpp_quote
("#define PDF_VECTOR 0x00000020")
452 typedef struct tagMIMEPARAMINFO
456 } MIMEPARAMINFO
, *LPMIMEPARAMINFO
;
458 typedef enum tagPROPINFOMASK
461 PIM_ENCODINGTYPE
= 0x02,
462 PIM_ROWNUMBER
= 0x04,
466 PIM_VTDEFAULT
= 0x40,
470 typedef struct tagMIMEPROPINFO
474 ENCODINGTYPE ietEncoding
;
481 } MIMEPROPINFO
, *LPMIMEPROPINFO
;
482 typedef const MIMEPROPINFO
*LPCMIMEPROPINFO
;
486 [in,out] LPMIMEPROPINFO pInfo
);
490 [in] LPCMIMEPROPINFO pInfo
);
492 cpp_quote
("#ifdef WINE_NO_UNICODE_MACROS")
493 cpp_quote
("#undef GetProp")
494 cpp_quote
("#undef SetProp")
495 cpp_quote
("#undef EnumProps")
500 [in,out] LPPROPVARIANT pValue
);
505 [in] LPCPROPVARIANT pValue
);
510 [in] LPPROPVARIANT pValue
);
513 [in] LPCSTR pszName
);
517 [in,unique] LPCSTR
*prgszName
,
518 [in] IMimePropertySet
*pPropertySet
);
522 [in] LPCSTR
*prgszName
,
523 [in] IMimePropertySet
*pPropertySet
);
525 HRESULT DeleteExcept
(
527 [in] LPCSTR
*prgszName
);
531 [in] LPCSTR pszCriteria
,
532 [in] boolean fSubString
,
533 [in] boolean fCaseSensitive
);
536 [out] LPHCHARSET phCharset
);
539 [in] HCHARSET hCharset
,
540 [in] CSETAPPLYTYPE applytype
);
542 HRESULT GetParameters
(
544 [out] ULONG
*pcParams
,
545 [out] LPMIMEPARAMINFO
*pprgParam
);
547 HRESULT IsContentType
(
548 [in] LPCSTR pszPriType
,
549 [in,unique] LPCSTR pszSubType
);
551 HRESULT BindToObject
(
553 [out,iid_is(riid
)] void **ppvObject
);
556 [out] IMimePropertySet
**ppPropertySet
);
559 [in] const TYPEDID oid
,
560 [in] LPCPROPVARIANT pValue
);
563 [in] const TYPEDID oid
,
564 [in,out] LPPROPVARIANT pValue
);
566 cpp_quote
("#define EPF_NONAME 0x00000001")
570 [out] IMimeEnumProperties
**ppEnum
);
575 uuid(c558834a
-7f86
-11d0
-8252-00c04fd85ab4
),
578 interface IMimeAddressTable
: IUnknown
580 typedef [unique] IMimeAddressTable
*LPMIMEADDRESSTABLE
;
582 DECLARE_HANDLE
(HADDRESS
);
583 typedef HADDRESS
*LPHADDRESS
;
584 typedef DWORD IADDRESSTYPE
;
586 typedef enum tagADDRESSFORMAT
588 AFT_DISPLAY_FRIENDLY
,
596 typedef struct tagADDRESSPROPS
600 ENCODINGTYPE ietFriendly
;
608 THUMBBLOB tbEncryption
;
612 } ADRESSPROPS
, *LPADDRESSPROPS
;
614 typedef struct tagADDRESSLIST
617 LPADDRESSPROPS prgAdr
;
618 } ADDRESSLIST
, *LPADDRESSLIST
;
620 /* FIXME: fill this in */
624 uuid(ee519f11
-851a
-11d0
-8252-00c04fd85ab4
),
627 interface IMimeWebDocument
: IUnknown
629 /* FIXME: fill this in */
633 uuid(c558834c
-7f86
-11d0
-8252-00c04fd85ab4
),
636 interface IMimeBody
: IMimePropertySet
638 typedef [unique] IMimeBody
*LPMIMEBODY
;
640 typedef enum tagIMSGBODYTYPE
649 typedef struct tagBODYOFFSETS
651 DWORD cbBoundaryStart
;
655 } BODYOFFSETS
, *LPBODYOFFSETS
;
657 typedef struct tagTRANSMITINFO
659 ENCODINGTYPE ietCurrent
;
660 ENCODINGTYPE ietXmitMime
;
661 ENCODINGTYPE ietXmit822
;
667 } TRANSMITINFO
, *LPTRANSMITINFO
;
670 [in] IMSGBODYTYPE bodytype
);
672 HRESULT SetDisplayName
(
673 [in] LPCSTR pszDisplay
);
675 HRESULT GetDisplayName
(
676 [out] LPSTR
*ppszDisplay
);
679 [out] LPBODYOFFSETS pOffsets
);
681 HRESULT GetCurrentEncoding
(
682 [out] ENCODINGTYPE
*pietEncoding
);
684 HRESULT SetCurrentEncoding
(
685 [in] ENCODINGTYPE ietEncoding
);
687 HRESULT GetEstimatedSize
(
688 [in] ENCODINGTYPE ietEncoding
,
689 [out] ULONG
*pcbSize
);
692 [in] ENCODINGTYPE ietEncoding
,
693 [in] IStream
*pStream
);
696 [in] ENCODINGTYPE ietEncoding
,
697 [out] IStream
**ppStream
);
700 [in] ENCODINGTYPE ietEncoding
,
701 [in,unique] LPCSTR pszPriType
,
702 [in,unique] LPCSTR pszSubType
,
704 [in,iid_is(riid
)] LPVOID pvObject
);
706 HRESULT EmptyData
(void);
709 [in] IMimeBody
*pBody
);
711 HRESULT GetTransmitInfo
(
712 [in,out] LPTRANSMITINFO pTransmitInfo
);
715 [in] ENCODINGTYPE ietEncoding
,
716 [in] LPCSTR pszFilePath
);
719 [out] LPHBODY phBody
);
724 uuid(fd853cd4
-7f86
-11d0
-8252-00c04fd85ab4
),
727 interface IMimeMessageTree
: IPersistStreamInit
729 typedef [unique] IMimeMessageTree
*LPMIMEMESSAGETREE
;
731 const HBODY HBODY_ROOT
= (HBODY
)-1;
733 typedef enum tagBODYLOCATION
743 typedef struct tagFINDBODY
748 } FINDBODY
, *LPFINDBODY
;
750 HRESULT GetMessageSource
(
751 [out] IStream
**ppStream
,
754 HRESULT GetMessageSize
(
755 [out] ULONG
*pcbSize
,
758 HRESULT LoadOffsetTable
(
759 [in] IStream
*pStream
);
761 HRESULT SaveOffsetTable
(
762 [in] IStream
*pStream
,
766 [out] DWORD
*pdwFlags
);
771 HRESULT HandsOffStorage
();
773 HRESULT BindToObject
(
774 [in] const HBODY hBody
,
776 [out, iid_is(riid
)] void **ppvObject
);
781 [in] IStream
*pStream
);
784 [in] BODYLOCATION location
,
786 [out] LPHBODY phBody
);
789 [in] BODYLOCATION location
,
791 [out] LPHBODY phBody
);
799 [in] BODYLOCATION location
);
803 [in] boolean fRecurse
,
804 [out] ULONG
*pcBodies
);
807 [in, out] LPFINDBODY pFindBody
,
808 [out] LPHBODY phBody
);
811 [in, out] LPFINDBODY pFindBody
,
812 [out] LPHBODY phBody
);
819 [out] LPHBODY phBody
);
823 [in] LPCSTR pszSubType
,
824 [out] LPHBODY phMultipart
);
826 HRESULT GetBodyOffsets
(
828 [in, out] LPBODYOFFSETS pOffsets
);
831 [out] LPHCHARSET phCharset
);
834 [in] HCHARSET hCharset
,
835 [in] CSETAPPLYTYPE applytype
);
839 [in] IMSGBODYTYPE bodytype
);
841 HRESULT IsContentType
(
843 [in] LPCSTR pszPriType
,
844 [in] LPCSTR pszSubType
);
846 HRESULT QueryBodyProp
(
849 [in] LPCSTR pszCriteria
,
850 [in] boolean fSubString
,
851 [in] boolean fCaseSensitive
);
857 [in, out] LPPROPVARIANT pValue
);
863 [in] LPCPROPVARIANT pValue
);
865 HRESULT DeleteBodyProp
(
867 [in] LPCSTR pszName
);
870 [in] const TYPEDID oid
,
871 [in] LPCPROPVARIANT pValue
);
874 [in] const TYPEDID oid
,
875 [in, out] LPPROPVARIANT pValue
);
879 uuid(fd853cd5
-7f86
-11d0
-8252-00c04fd85ab4
),
882 interface IMimeMessage
: IMimeMessageTree
884 typedef [unique] IMimeMessage
*LPMIMEMESSAGE
;
886 typedef DWORD TEXTTYPE
;
888 typedef enum tagIMSGFLAGS
890 IMF_ATTACHMENTS
= 0x00000001,
891 IMF_MULTIPART
= 0x00000002,
892 IMF_SUBMULTIPART
= 0x00000004,
893 IMF_MIME
= 0x00000008,
894 IMF_HTML
= 0x00000010,
895 IMF_PLAIN
= 0x00000020,
896 IMF_PARTIAL
= 0x00000040,
897 IMF_SIGNED
= 0x00000080,
898 IMF_ENCRYPTED
= 0x00000100,
899 IMF_TNEF
= 0x00000200,
900 IMF_MHTML
= 0x00000400,
901 IMF_SECURE
= 0x00000800,
902 IMF_TEXT
= 0x00001000,
903 IMF_CSETTAGGED
= 0x00002000,
904 IMF_NEWS
= 0x00004000,
905 IMF_VOICEMAIL
= 0x00008000,
906 IMF_HASVCARD
= 0x00010000,
907 IMF_RFC1154
= 0x00020000,
910 typedef enum tagIMSGPRIORITY
917 cpp_quote
("#define WPF_HTML 0x00000001")
918 cpp_quote
("#define WPF_AUTOINLINE 0x00000002")
919 cpp_quote
("#define WPF_SLIDESHOW 0x00000004")
920 cpp_quote
("#define WPF_ATTACHLINKS 0x00000008")
921 cpp_quote
("#define WPF_IMAGESONLY 0x00000010")
922 cpp_quote
("#define WPF_NOMETACHARSET 0x00000020")
924 typedef struct tagWEPAGEOPTIONS
930 } WEBPAGEOPTIONS
, *LPWEBPAGEOPTIONS
;
932 cpp_quote
("#define TXT_PLAIN 1")
933 cpp_quote
("#define TXT_HTML 2")
935 HRESULT CreateWebPage
(
936 [in] IStream
*pRootStm
,
937 [in] LPWEBPAGEOPTIONS pOptions
,
938 [in] IMimeMessageCallback
*pCallback
,
939 [out] IMoniker
**ppMoniker
);
944 [in,out] LPPROPVARIANT pValue
);
949 [in] LPCPROPVARIANT pValue
);
952 [in] LPCSTR pszName
);
956 [in] LPCSTR pszCriteria
,
957 [in] boolean fSubString
,
958 [in] boolean fCaseSensitive
);
961 [in] DWORD dwTxtType
,
962 [in] ENCODINGTYPE ietEncoding
,
963 [out] IStream
**pStream
,
964 [out] LPHBODY phBody
);
967 [in] DWORD dwTxtType
,
968 [in] ENCODINGTYPE ietEncoding
,
969 [in] HBODY hAlternative
,
970 [in] IStream
*pStream
,
971 [out] LPHBODY phBody
);
973 HRESULT AttachObject
(
975 [in, iid_is(riid
)] void *pvObject
,
976 [out] LPHBODY phBody
);
979 [in] LPCSTR pszFilePath
,
980 [in] IStream
*pstmFile
,
981 [out] LPHBODY phBody
);
987 [in] IStream
*pstmURL
,
988 [out] LPSTR
*ppszCIDURL
,
989 [out] LPHBODY phBody
);
991 HRESULT GetAttachments
(
992 [out] ULONG
*pcAttach
,
993 [out] LPHBODY
*pprghAttach
);
995 HRESULT GetAddressTable
(
996 [out] IMimeAddressTable
**ppTable
);
999 [in, out] LPADDRESSPROPS pAddress
);
1001 HRESULT GetAddressTypes
(
1002 [in] DWORD dwAdrTypes
,
1004 [in, out] LPADDRESSLIST pList
);
1006 HRESULT GetAddressFormat
(
1007 [in] DWORD dwAdrTypes
,
1008 [in] ADDRESSFORMAT format
,
1009 [out] LPSTR
*ppszFormat
);
1011 HRESULT EnumAddressTypes
(
1012 [in] DWORD dwAdrTypes
,
1014 [out] IMimeEnumAddressTypes
**ppEnum
);
1016 HRESULT SplitMessage
(
1017 [in] ULONG cbMaxPart
,
1018 [out] IMimeMessageParts
**ppParts
);
1020 HRESULT GetRootMoniker
(
1021 [out] IMoniker
**ppMoniker
);
1025 uuid(761aa741
-7bda
-11d1
-8aa9
-00c04fb951f3
),
1028 interface IMimeMessageCallback
: IUnknown
1030 HRESULT OnWebPageSplitter
(
1031 [in] DWORD cInlined
,
1032 [in] IStream
*ppStream
);
1036 uuid(de4ad8da
-555f
-11d1
-8dd0
-00c04fb951f9
),
1039 interface IPersistMime
: IPersist
1041 /* FIXME: fill this in */
1045 uuid(c558834f
-7f86
-11d0
-8252-00c04fd85ab4
),
1048 interface IMimeMessageParts
: IUnknown
1050 /* FIXME: fill this in */
1054 uuid(c558834d
-7f86
-11d0
-8252-00c04fd85ab4
),
1057 interface IMimeEnumHeaderRows
: IUnknown
1059 typedef struct tagENUMHEADERROW
1065 DWORD_PTR dwReserved
;
1066 } ENUMHEADERROW
, *LPENUMHEADERROW
;
1068 /* FIXME: fill this in */
1072 uuid(fd853cee
-7f86
-11d0
-8252-00c04fd85ab4
),
1075 interface IMimeEnumProperties
: IUnknown
1077 typedef [unique] IMimeEnumProperties
*LPMIMEENUMPROPERTIES
;
1079 typedef struct tagENUMPROPERTY
1084 } ENUMPROPERTY
, *LPENUMPROPERTY
;
1088 [in, out] LPENUMPROPERTY prgProp
,
1089 [out] ULONG
*pcFetched
);
1094 HRESULT Reset
(void);
1097 [out] IMimeEnumProperties
**ppEnum
);
1100 [out] ULONG
*pcItems
);
1105 uuid(c5588354
-7f86
-11d0
-8252-00c04fd85ab4
),
1108 interface IMimeEnumAddressTypes
: IUnknown
1110 /* FIXME: fill this in */
1114 uuid(c5588350
-7f86
-11d0
-8252-00c04fd85ab4
),
1117 interface IMimeEnumMessageParts
: IUnknown
1119 /* FIXME: fill this in */
1123 uuid(64577981-86d7
-11d1
-bdfc
-00c04fa31009
),
1126 interface IHashTable
: IUnknown
1128 /* FIXME: fill this in */
1132 uuid(c5588351
-7f86
-11d0
-8252-00c04fd85ab4
),
1135 interface IMimeAllocator
: IMalloc
1137 typedef [unique] IMimeAllocator
*LPMIMEALLOCATOR
;
1139 HRESULT FreeParamInfoArray
(
1141 [in] LPMIMEPARAMINFO prgParam
,
1142 [in] boolean fFreeArray
);
1144 HRESULT FreeAddressList
(
1145 [in,out] LPADDRESSLIST pList
);
1147 HRESULT FreeAddressProps
(
1148 [in,out] LPADDRESSPROPS pAddress
);
1150 HRESULT ReleaseObjects
(
1151 [in] ULONG cObjects
,
1152 [in] IUnknown
**prgpUnknown
,
1153 [in] boolean fFreeArray
);
1155 HRESULT FreeEnumHeaderRowArray
(
1157 [in] LPENUMHEADERROW prgRow
,
1158 [in] boolean fFreeArray
);
1160 HRESULT FreeEnumPropertyArray
(
1162 [in] LPENUMPROPERTY prgProp
,
1163 [in] boolean fFreeArray
);
1165 HRESULT FreeThumbprint
(
1166 [in] THUMBBLOB
*pthumbprint
);
1168 HRESULT PropVariantClear
(
1169 [in] LPPROPVARIANT pProp
);
1174 uuid(feceaffd
-c441
-11d1
-960e-00c04fbd7c09
),
1177 interface IMimeObjResolver
: IUnknown
1179 /* FIXME: fill this in */
1183 uuid(b0d17fc2
-7bc4
-11d1
-bdfa
-00c04fa31009
),
1186 interface IFontCache
: IUnknown
1188 /* FIXME: fill this in */
1192 uuid(b0d17fc5
-7bc4
-11d1
-bdfa
-00c04fa31009
),
1195 interface IFontCacheNotify
: IUnknown
1197 /* FIXME: fill this in */
1201 uuid(70183210-7b36
-11d2
-8c12
-00c04fa31009
),
1204 interface IMimeEditTag
: IUnknown
1206 /* FIXME: fill this in */
1210 uuid(d09ee528
-7b38
-11d2
-8c12
-00c04fa31009
),
1213 interface IMimeEditTagCollection
: IUnknown
1215 /* FIXME: fill this in */
1219 uuid(ba715ae0
-a740
-11d2
-8b22
-0080c76b34c6
),
1222 interface IMimeSecurityCallback
: IUnknown
1224 /* FIXME: fill this in */
1226 cpp_quote
("#define CMS_RECIPIENT_INFO_TYPE_UNKNOWN 0")
1227 cpp_quote
("#define CMS_RECIPIENT_INFO_TYPE_KEYTRANS 1")
1228 cpp_quote
("#define CMS_RECIPIENT_INFO_TYPE_KEYAGREE 2")
1229 cpp_quote
("#define CMS_RECIPIENT_INFO_TYPE_MAIL_LIST 3")
1231 cpp_quote
("#define CMS_RECIPIENT_INFO_PUBKEY_CERTIFICATE 0")
1232 cpp_quote
("#define CMS_RECIPIENT_INFO_PUBKEY_KEYTRANS 1")
1233 cpp_quote
("#define CMS_RECIPIENT_INFO_PUBKEY_PROVIDER 2")
1234 cpp_quote
("#define CMS_RECIPIENT_INFO_PUBKEY_EPHEMERAL_KEYAGREE 3")
1235 cpp_quote
("#define CMS_RECIPIENT_INFO_PUBKEY_STATIC_KEYAGREE 4")
1237 cpp_quote
("#define CMS_RECIPIENT_INFO_KEYID_CERTIFICATE 0")
1238 cpp_quote
("#define CMS_RECIPIENT_INFO_KEYID_ISSUERSERIAL 1")
1239 cpp_quote
("#define CMS_RECIPIENT_INFO_KEYID_KEY_ID 2")
1244 cpp_quote
("#ifdef __cplusplus")
1245 cpp_quote
(" extern \"C\" {")
1249 cpp_quote
("HRESULT WINAPI MimeOleSetCompatMode(DWORD);")
1250 cpp_quote
("HRESULT WINAPI MimeOleContentTypeFromUrl(LPCSTR,LPCSTR,LPSTR*);")
1251 cpp_quote
("HRESULT WINAPI MimeOleParseMhtmlUrl(LPSTR,LPSTR*,LPSTR*);")
1252 cpp_quote
("HRESULT WINAPI MimeOleObjectFromUrl(LPCSTR,BOOL,REFIID,LPVOID*,IUnknown**);")
1253 cpp_quote
("HRESULT WINAPI MimeOleObjectFromMoniker(BINDF,IMoniker*,IBindCtx*,REFIID,LPVOID*,IMoniker**);")
1254 cpp_quote
("HRESULT WINAPI MimeOleCombineURL(LPCSTR,ULONG,LPCSTR,ULONG,BOOL,LPSTR*);")
1255 cpp_quote
("HRESULT WINAPI MimeOleGetSubjectFileName(IMimePropertySet*,ULONG*,ULONG*,LPSTR,ULONG);")
1256 cpp_quote
("HRESULT WINAPI MimeOleCreateWebDocument(LPCSTR,LPCSTR,IMimeWebDocument**);")
1257 cpp_quote
("HRESULT WINAPI MimeOleGetRelatedSection(IMimeMessageTree*,boolean,LPHBODY,boolean*);")
1258 cpp_quote
("HRESULT WINAPI MimeOleGetMixedSection(IMimeMessageTree*,boolean,LPHBODY,boolean*);")
1259 cpp_quote
("HRESULT WINAPI MimeOleGetAlternativeSection(IMimeMessageTree*,LPHBODY,boolean*);")
1260 cpp_quote
("HRESULT WINAPI MimeOleGenerateCID(LPSTR,ULONG,boolean);")
1261 cpp_quote
("HRESULT WINAPI MimeOleGenerateMID(LPSTR,ULONG,boolean);")
1262 cpp_quote
("HRESULT WINAPI MimeOleCreateByteStream(IStream**);")
1263 cpp_quote
("HRESULT WINAPI MimeOlGetPropertySchema(IMimePropertySchema**);")
1264 cpp_quote
("HRESULT WINAPI MimeOleQueryString(LPCSTR,LPCSTR,boolean,boolean);")
1265 cpp_quote
("HRESULT WINAPI MimeOleGetPropA(IMimePropertySet*,LPCSTR,DWORD,LPSTR*);")
1266 cpp_quote
("HRESULT WINAPI MimeOleSetPropA(IMimePropertySet*,LPCSTR,DWORD,LPCSTR);")
1267 cpp_quote
("HRESULT WINAPI MimeOleGetPropW(IMimePropertySet*,LPCSTR,DWORD,LPWSTR*);")
1268 cpp_quote
("HRESULT WINAPI MimeOleSetPropW(IMimePropertySet*,LPCSTR,DWORD,LPCWSTR);")
1269 cpp_quote
("HRESULT WINAPI MimeOleGetBodyPropA(IMimeMessageTree*,HBODY,LPCSTR,DWORD,LPSTR*);")
1270 cpp_quote
("HRESULT WINAPI MimeOleSetBodyPropA(IMimeMessageTree*,HBODY,LPCSTR,DWORD,LPCSTR);")
1271 cpp_quote
("HRESULT WINAPI MimeOleGetBodyPropW(IMimeMessageTree*,HBODY,LPCSTR,DWORD,LPWSTR*);")
1272 cpp_quote
("HRESULT WINAPI MimeOleSetBodyPropW(IMimeMessageTree*,HBODY,LPCSTR,DWORD,LPCWSTR);")
1273 cpp_quote
("HRESULT WINAPI MimeOleCreateHeaderTable(IMimeHeaderTable**);")
1274 cpp_quote
("HRESULT WINAPI MimeOleVariantFree(LPPROPVARIANT);")
1275 cpp_quote
("HRESULT WINAPI MimeOleVariantCopy(LPPROPVARIANT,LPPROPVARIANT);")
1276 cpp_quote
("HRESULT WINAPI MimeOleGetExtClassId(LPCSTR,LPCLSID);")
1277 cpp_quote
("HRESULT WINAPI MimeOleEncodeHeader(HCHARSET,LPPROPVARIANT,LPSTR*,LPRFC1522INFO);")
1278 cpp_quote
("HRESULT WINAPI MimeOleDecodeHeader(HCHARSET,LPCSTR,LPPROPVARIANT,LPRFC1522INFO);")
1279 cpp_quote
("HRESULT WINAPI MimeOleRfc1522Decode(LPCSTR,LPSTR,ULONG,LPSTR*);")
1280 cpp_quote
("HRESULT WINAPI MimeOleRfc1522Encode(LPCSTR,HCHARSET,LPSTR*);")
1281 cpp_quote
("HRESULT WINAPI MimeOleGetInternat(IMimeInternational**);")
1282 cpp_quote
("HRESULT WINAPI MimeOleFindCharset(LPCSTR,LPHCHARSET);")
1283 cpp_quote
("HRESULT WINAPI MimeOleGetCharsetInfo(HCHARSET,LPINETCSETINFO);")
1284 cpp_quote
("HRESULT WINAPI MimeOleGetCodePageInfo(HCHARSET,LPCODEPAGEINFO);")
1285 cpp_quote
("HRESULT WINAPI MimeOleGetDefaultCharset(LPHCHARSET);")
1286 cpp_quote
("HRESULT WINAPI MimeOleSetDefaultCharset(HCHARSET);")
1287 cpp_quote
("HRESULT WINAPI MimeOleGetCodePageCharset(CODEPAGEID,CHARSETTYPE,LPHCHARSET);")
1288 cpp_quote
("HRESULT WINAPI MimeOleCreateVirtualStream(IStream**);")
1289 cpp_quote
("HRESULT WINAPI MimeOleOpenFileStream(LPCSTR,DWORD,DWORD,IStream**);")
1290 cpp_quote
("HRESULT WINAPI MimeOleIsTnefStream(IStream*);")
1291 cpp_quote
("HRESULT WINAPI MimeOleGenerateFileName(LPCSTR,LPCSTR,LPCSTR,LPSTR*);")
1292 cpp_quote
("HRESULT WINAPI MimeOleGetFileExtension(LPCSTR,LPSTR,ULONG);")
1293 cpp_quote
("HRESULT WINAPI MimeOleCreateSecurity(IMimeSecurity**);")
1294 cpp_quote
("HRESULT WINAPI MimeOleInetDateToFileTime(LPCSTR,LPFILETIME);")
1295 cpp_quote
("HRESULT WINAPI MimeOleFileTimeToInetDate(LPFILETIME,LPSTR,ULONG);")
1296 cpp_quote
("HRESULT WINAPI MimeOleCreateMessageParts(IMimeMessageParts**);")
1297 cpp_quote
("HRESULT WINAPI MimeOleGetAllocator(IMimeAllocator**);")
1298 cpp_quote
("HRESULT WINAPI MimeOleParseRfc822Address(DWORD,ENCODINGTYPE,LPCSTR,LPADDRESSLIST);")
1299 cpp_quote
("HRESULT WINAPI MimeOleCreateMessage(IUnknown*,IMimeMessage**);")
1300 cpp_quote
("HRESULT WINAPI MimeOleMergePartialHeaders(IStream*,IStream*);")
1301 cpp_quote
("HRESULT WINAPI MimeOleEscapeString(CODEPAGEID,LPCSTR,LPSTR*);")
1302 cpp_quote
("HRESULT WINAPI MimeOleGetExtContentType(LPCSTR,LPSTR*);")
1303 cpp_quote
("HRESULT WINAPI MimeOleGetContentTypeExt(LPCSTR,LPSTR*);")
1304 cpp_quote
("HRESULT WINAPI MimeOleGetFileInfo(LPSTR,LPSTR*,LPSTR*,LPSTR*,LPSTR*,LPSTR*);")
1305 cpp_quote
("HRESULT WINAPI MimeOleCreateBody(IMimeBody**);")
1306 cpp_quote
("HRESULT WINAPI MimeOleCreatePropertySet(IUnknown*,IMimePropertySet**);")
1307 cpp_quote
("HRESULT WINAPI MimeOleCreateMessageTree(IUnknown*,IMimeMessageTree**);")
1308 cpp_quote
("HRESULT WINAPI MimeOleGetCertsFromThumbprints(THUMBBLOB*,X509CERTRESULT*,const HCERTSTORE*,DWORD);")
1309 cpp_quote
("HRESULT WINAPI MimeOleSplitMessage(IMimeMessage*,ULONG,IMimeMessageParts**);")
1310 cpp_quote
("HRESULT WINAPI MimeOleClearDirtyTree(IMimeMessageTree*);")
1311 cpp_quote
("HRESULT WINAPI MimeOleConvertEnrichedToHTML(CODEPAGEID,IStream*,IStream*);")
1312 cpp_quote
("HRESULT WINAPI MimeOleSMimeCapsToDlg(LPBYTE,DWORD,DWORD,PCX509CERT*,HWND,DWORD,DWORD,DWORD);")
1313 cpp_quote
("HRESULT WINAPI MimeOleSMimeCapsFromDlg(HWND,DWORD,DWORD,DWORD,LPBYTE,DWORD*);")
1314 cpp_quote
("HRESULT WINAPI MimeOleSMimeCapInit(LPBYTE,DWORD,LPVOID*);")
1315 cpp_quote
("HRESULT WINAPI MimeOleSMimeCapAddSMimeCap(LPBYTE,DWORD,LPVOID);")
1316 cpp_quote
("HRESULT WINAPI MimeOleSMimeCapAddCert(LPBYTE,DWORD,BOOL,LPVOID);")
1317 cpp_quote
("HRESULT WINAPI MimeOleSMimeCapGetEncAlg(LPVOID,LPBYTE,DWORD*,DWORD*);")
1318 cpp_quote
("HRESULT WINAPI MimeOleSMimeCapGetHashAlg(LPVOID,LPBYTE,DWORD*,DWORD*);")
1319 cpp_quote
("HRESULT WINAPI MimeOleSMimeCapRelease(LPVOID);")
1320 cpp_quote
("HRESULT WINAPI MimeOleAlgNameFromSMimeap(LPBYTE,DWORD,LPCSTR*);")
1321 cpp_quote
("HRESULT WINAPI MimeOleAlgStrengthFromSMimeCap(LPBYTE,DWORD,BOOL,DWORD*);")
1322 cpp_quote
("HRESULT WINAPI MimeOleSMimeCapsFull(LPVOID,BOOL,BOOL,LPBYTE,DWORD*);")
1323 cpp_quote
("HRESULT WINAPI MimeOleCreateHashTable(DWORD,BOOL,IHashTable**);")
1324 cpp_quote
("HRESULT WINAPI MimeOleStripHeaders(IMimeMessage*,HBODY,LPCSTR,LPCSTR,IStream**);")
1326 cpp_quote
("HRESULT WINAPI MimeEditViewSource(HWND,IMimeMessage*);")
1327 cpp_quote
("HRESULT WINAPI MimeEditIsSafeToRun(HWND,LPCSTR);")
1328 cpp_quote
("HRESULT WINAPI MimeEditVerifyTrust(HWND,LPCSTR,LPCSTR);")
1329 cpp_quote
("HRESULT WINAPI MimeEditCreateMimeDocument(IUnknown*,IMimeMessage*,DWORD,IMimeMessage**);")
1330 cpp_quote
("HRESULT WINAPI MimeEditGetBackgroundImageUrl(IUnknown*,BSTR*);")
1331 cpp_quote
("HRESULT WINAPI MimeEditDocumentFromStream(IStream*,REFIID,void**);")
1333 cpp_quote
("#ifdef __cplusplus")