28cpp_quote(
"DEFINE_GUID(CLSID_IInternetMessageUrl, 0xca30cc91, 0xb1b3, 0x11d0, 0x85, 0xd0, 0x00, 0xc0, 0x4f, 0xd8, 0x5a, 0xb4);")
29cpp_quote("
DEFINE_GUID(CLSID_ISMTPTransport, 0xfd853ce6, 0x7f86, 0x11d0, 0x82, 0x52, 0x00, 0xc0, 0x4f, 0xd8, 0x5a, 0xb4);")
30cpp_quote("
DEFINE_GUID(CLSID_ISMTPTransport2, 0xdf2c7eC, 0x3435, 0x11d0, 0x81, 0xd0, 0
x0, 0xc0, 0x4f, 0xd8, 0x5a, 0xb4);")
31cpp_quote("
DEFINE_GUID(CLSID_IPOP3Transport, 0xfd853ce7, 0x7f86, 0x11d0, 0x82, 0x52, 0x00, 0xc0, 0x4f, 0xd8, 0x5a, 0xb4);")
32cpp_quote("
DEFINE_GUID(CLSID_INNTPTransport, 0xfd853ce8, 0x7f86, 0x11d0, 0x82, 0x52, 0x00, 0xc0, 0x4f, 0xd8, 0x5a, 0xb4);")
33cpp_quote("
DEFINE_GUID(CLSID_IRASTransport, 0xfd853ce9, 0x7f86, 0x11d0, 0x82, 0x52, 0x00, 0xc0, 0x4f, 0xd8, 0x5a, 0xb4);")
34cpp_quote("
DEFINE_GUID(CLSID_IRangeList, 0xfd853cea, 0x7f86, 0x11d0, 0x82, 0x52, 0x00, 0xc0, 0x4f, 0xd8, 0x5a, 0xb4);")
35cpp_quote("
DEFINE_GUID(CLSID_IIMAPTransport, 0xfd853ceb, 0x7f86, 0x11d0, 0x82, 0x52, 0x00, 0xc0, 0x4f, 0xd8, 0x5a, 0xb4);")
36cpp_quote("
DEFINE_GUID(CLSID_IHTTPMailTransport, 0x5a580c11, 0xe5eb, 0x11d1, 0xa8, 0x6e, 0x00, 0x00, 0xf8, 0x08, 0x4f, 0x96);")
37cpp_quote("
DEFINE_GUID(CLSID_IPropFindRequest, 0xbb847b8a, 0x054a, 0x11d2, 0xa8, 0x94, 0x00, 0x00, 0xf8, 0x08, 0x4f, 0x96);")
38cpp_quote("
DEFINE_GUID(CLSID_IPropPatchRequest, 0xea678830, 0x235d, 0x11d2, 0xa8, 0xb6, 0x00, 0x00, 0xf8, 0x08, 0x4f, 0x96);")
43cpp_quote("#define HR_E(n) MAKE_SCODE(SEVERITY_ERROR, FACILITY_INTERNET, n)")
45cpp_quote("#ifndef HR_S")
46cpp_quote("#define HR_S(n) MAKE_SCODE(SEVERITY_SUCCESS, FACILITY_INTERNET, n)")
49/* General Error Codes */
50cpp_quote("#define IXP_E_LOAD_SICILY_FAILED HR_E(0xCC00)")
51cpp_quote("#define IXP_E_INVALID_CERT_CN HR_E(0xCC01)")
52cpp_quote("#define IXP_E_INVALID_CERT_DATE HR_E(0xCC02)")
53cpp_quote("#define IXP_E_ALREADY_CONNECTED HR_E(0xCC03)")
54cpp_quote("#define IXP_E_CONN HR_E(0xCC04)")
55cpp_quote("#define IXP_E_NOT_CONNECTED HR_E(0xCC05)")
56cpp_quote("#define IXP_E_CONN_SEND HR_E(0xCC06)")
57cpp_quote("#define IXP_E_WOULD_BLOCK HR_E(0xCC07)")
58cpp_quote("#define IXP_E_INVALID_STATE HR_E(0xCC08)")
59cpp_quote("#define IXP_E_CONN_RECV HR_E(0xCC09)")
60cpp_quote("#define IXP_E_INCOMPLETE HR_E(0xCC0A)")
61cpp_quote("#define IXP_E_BUSY HR_E(0xCC0B)")
62cpp_quote("#define IXP_E_NOT_INIT HR_E(0xCC0C)")
63cpp_quote("#define IXP_E_CANT_FIND_HOST HR_E(0xCC0D)")
64cpp_quote("#define IXP_E_FAILED_TO_CONNECT HR_E(0xCC0E)")
65cpp_quote("#define IXP_E_CONNECTION_DROPPED HR_E(0xCC0F)")
66cpp_quote("#define IXP_E_INVALID_ADDRESS HR_E(0xCC10)")
67cpp_quote("#define IXP_E_INVALID_ADDRESS_LIST HR_E(0xCC11)")
68cpp_quote("#define IXP_E_SOCKET_READ_ERROR HR_E(0xCC12)")
69cpp_quote("#define IXP_E_SOCKET_WRITE_ERROR HR_E(0xCC13)")
70cpp_quote("#define IXP_E_SCOKET_INIT_ERROR HR_E(0xCC14)")
71cpp_quote("#define IXP_E_SOCKET_CONNECT_ERROR HR_E(0xCC15)")
72cpp_quote("#define IXP_E_INVALID_ACCOUNT HR_E(0xCC16)")
73cpp_quote("#define IXP_E_USER_CANCEL HR_E(0xCC17)")
74cpp_quote("#define IXP_E_SICILY_LOGON_FAILED HR_E(0xCC18)")
75cpp_quote("#define IXP_E_TIMEOUT HR_E(0xCC19)")
76cpp_quote("#define IXP_E_SECURE_CONNECT_FAILED HR_E(0xCC1A)")
78/* SMTP Failure Statuses */
79cpp_quote("#define IXP_E_SMTP_RESPONSE_ERROR HR_E(0xCC60)")
80cpp_quote("#define IXP_E_SMTP_UNKNOWN_RESPONSE_CODE HR_E(0xCC61)")
81cpp_quote("#define IXP_E_SMTP_500_SYNTAX_ERROR HR_E(0xCC62)")
82cpp_quote("#define IXP_E_SMTP_501_PARAM_SYNTAX HR_E(0xCC63)")
83cpp_quote("#define IXP_E_SMTP_502_COMMAND_NOTIMPL HR_E(0xCC64)")
84cpp_quote("#define IXP_E_SMTP_503_COMMAND_SEQ HR_E(0xCC65)")
85cpp_quote("#define IXP_E_SMTP_504_COMMAND_PARAM_NOTIMPL HR_E(0xCC66)")
86cpp_quote("#define IXP_E_SMTP_421_NOT_AVAILABLE HR_E(0xCC67)")
87cpp_quote("#define IXP_E_SMTP_450_MAILBOX_BUSY HR_E(0xCC68)")
88cpp_quote("#define IXP_E_SMTP_550_MAILBOX_NOT_FOUND HR_E(0xCC69)")
89cpp_quote("#define IXP_E_SMTP_451_ERROR_PROCESSING HR_E(0xCC6A)")
90cpp_quote("#define IXP_E_SMTP_551_USER_NOT_LOCAL HR_E(0xCC6B)")
91cpp_quote("#define IXP_E_SMTP_452_NO_SYSTEM_STORAGE HR_E(0xCC6C)")
92cpp_quote("#define IXP_E_SMTP_552_STORAGE_OVERFLOW HR_E(0xCC6D)")
93cpp_quote("#define IXP_E_SMTP_553_MAILBOX_NAME_SYNTAX HR_E(0xCC6E)")
94cpp_quote("#define IXP_E_SMTP_554_TRANSACT_FAILED HR_E(0xCC6F)")
96/* SMTP Success Statuses */
97cpp_quote("#define IXP_E_SMTP_211_SYSTEM_STATUS HR_S(0xCC70)")
98cpp_quote("#define IXP_E_SMTP_214_HELP_MESSAGE HR_S(0xCC71)")
99cpp_quote("#define IXP_E_SMTP_220_READY HR_S(0xCC72)")
100cpp_quote("#define IXP_E_SMTP_221_CLOSING HR_S(0xCC73)")
101cpp_quote("#define IXP_E_SMTP_250_MAIL_ACTION_OKAY HR_S(0xCC74)")
102cpp_quote("#define IXP_E_SMTP_251_FORWARDING_MAIL HR_S(0xCC75)")
103cpp_quote("#define IXP_E_SMTP_354_START_MAIL_INPUT HR_S(0xCC76)")
104cpp_quote("#define IXP_E_SMTP_CONTINUE HR_S(0xCC77)")
105cpp_quote("#define IXP_E_SMTP_334_AUTH_READY_RESPONSE HR_S(0xCC78)")
106cpp_quote("#define IXP_E_SMTP_245_AUTH_SUCCESS HR_S(0xCC79)")
108/* More SMTP Failure Statuses */
109cpp_quote("#define IXP_E_SMTP_REJECTED_SENDER HR_E(0xCC78)")
110cpp_quote("#define IXP_E_SMTP_REJECTED_RECIPIENTS HR_E(0xCC79)")
111cpp_quote("#define IXP_E_SMTP_NO_SENDER HR_E(0xCC7A)")
112cpp_quote("#define IXP_E_SMTP_NO_RECIPIENTS HR_E(0xCC7B)")
113cpp_quote("#define IXP_E_SMTP_530_STARTTLS_REQUIRED HR_E(0xCC7C)")
114cpp_quote("#define IXP_E_SMTP_NO_STARTTLS_SUPPORT HR_E(0xCC7D)")
115cpp_quote("#define IXP_E_SMTP_NO_DSN_SUPPORT HR_E(0xCC7E)")
116cpp_quote("#define IXP_E_SMTP_454_STARTTLS_FAILED HR_E(0xCC7F)")
118const SHORT CCHMAX_DOMAIN = 256;
119const SHORT CCHMAX_PHONE_NUMBER = 128;
121const DWORD DEFAULT_IMAP_PORT = 143;
122const DWORD DEFAULT_POP3_PORT = 110;
123const DWORD DEFAULT_SMTP_PORT = 25;
124const DWORD DEFAULT_NNTP_PORT = 119;
126typedef enum tagINETADDRTYPE
131 ADDR_DSN_SUCCESS = 32,
132 ADDR_DSN_FAILURE = 64,
136const DWORD ADDR_TOFROM_MASK = 0x1;
137const DWORD ADDR_DSN_MASK = 0xf0;
139typedef enum tagDSNRET
146typedef struct tagINETADDR
148 INETADDRTYPE addrtype;
149 CHAR szEmail[CCHMAX_EMAIL_ADDRESS];
150} INETADDR, *LPINETADDR;
152typedef struct tagINETADDRLIST
155 LPINETADDR prgAddress;
156} INETADDRLIST, *LPINETADDRLIST;
158typedef enum tagRASCONNTYPE
165typedef enum tagHTTPMAILPROPTYPE
167 HTTPMAIL_PROP_INVALID,
169 HTTPMAIL_PROP_CONTACTS,
171 HTTPMAIL_PROP_OUTBOX,
172 HTTPMAIL_PROP_SENDMSG,
173 HTTPMAIL_PROP_SENTITEMS,
174 HTTPMAIL_PROP_DELETEDITEMS,
175 HTTPMAIL_PROP_DRAFTS,
176 HTTPMAIL_PROP_MSGFOLDERROOT,
181typedef enum tagHTTPMAILSPECIALFOLDER
184 HTTPMAIL_SF_UNRECOGNIZED,
186 HTTPMAIL_SF_DELETEDITEMS,
189 HTTPMAIL_SF_SENTITEMS,
190 HTTPMAIL_SF_CONTACTS,
191 HTTPMAIL_SF_CALENDAR,
192 HTTPMAIL_SF_MSNPROMO,
194} HTTPMAILSPECIALFOLDER;
196typedef enum tagHTTPMAILCONTACTTYPE
201} HTTPMAILCONTACTTYPE;
203const DWORD DAVNAMESPACE_UNKNOWN = 0xFFFFFFFF;
204const DWORD DAVNAMESPACE_DAV = 0;
205const DWORD DAVNAMESPACE_HOTMAIL = 1;
206const DWORD DAVNAMESPACE_HTTPMAIL = 2;
207const DWORD DAVNAMESPACE_MAIL = 3;
208const DWORD DAVNAMESPACE_CONTACTS = 4;
210cpp_quote("#define ISF_SMTP_USEIPFORHELO 0x01")
211cpp_quote("#define ISF_ALWAYSPROMPTFORPASSWORD 0x02")
212/* for SMTP - send EHLO and use STARTTLS if available: */
213cpp_quote("#define ISF_SSLONSAMEPORT 0x04")
214cpp_quote("#define ISF_QUERYDSNSUPPORT 0x08")
215/* for SMTP - send EHLO and use AUTH if available: */
216cpp_quote("#define ISF_QUERYAUTHSUPPORT 0x10")
218typedef struct INETSERVER
220 CHAR szAccount[CCHMAX_ACCOUNT_NAME];
221 CHAR szUserName[CCHMAX_USERNAME];
222 CHAR szPassword[CCHMAX_PASSWORD];
223 CHAR szServerName[CCHMAX_SERVER_NAME];
224 CHAR szConnectoid[CCHMAX_CONNECTOID];
225 RASCONNTYPE rasconntype;
231} INETSERVER, *LPINETSERVER;
233typedef enum tagIXPTYPE
243typedef enum tagIXPSTATUS
257const DWORD DEPTH_INFINITY = 0xFFFFFFFE;
259typedef DWORD MEMBERINFOFLAGS;
261const MEMBERINFOFLAGS HTTP_MEMBERINFO_COMMONPROPS = 0x0;
262const MEMBERINFOFLAGS HTTP_MEMBERINFO_FOLDERPROPS = 0x1;
263const MEMBERINFOFLAGS HTTP_MEMBERINFO_MESSAGEPROPS = 0x2;
264const MEMBERINFOFLAGS HTTP_MEMBERINFO_ALLPROPS = HTTP_MEMBERINFO_FOLDERPROPS | HTTP_MEMBERINFO_MESSAGEPROPS;
266typedef DWORD IMAP_MSGFLAGS;
268const IMAP_MSGFLAGS IMAP_MSG_NOFLAGS = 0x00;
269const IMAP_MSGFLAGS IMAP_MSG_ANSWERED = 0x01;
270const IMAP_MSGFLAGS IMAP_MSG_FLAGGED = 0x02;
271const IMAP_MSGFLAGS IMAP_MSG_DELETED = 0x04;
272const IMAP_MSGFLAGS IMAP_MSG_SEEN = 0x08;
273const IMAP_MSGFLAGS IMAP_MSG_DRAFT = 0x10;
274const IMAP_MSGFLAGS IMAP_MSG_ALLFLAGS = 0x1f;
278 uuid(CA30F3FF-C9AC-11D1-9A3A-00C04FA309D4),
281interface ITransportCallbackService : IUnknown
283 HRESULT GetParentWindow(
284 [in] DWORD dwReserved,
285 [out] HWND *phwndParent);
288 [out] LPDWORD pdwServerType,
289 [out] IImnAccount **ppAccount);
294 uuid(0DF2C7E1-3435-11D0-81D0-00C04FD85AB4),
297interface ITransportCallback : IUnknown
299 typedef struct tagIXPRESULT
304 HRESULT hrServerError;
307 } IXPRESULT, *LPIXPRESULT;
309 typedef enum tagCMDTYPE
316 [in,out] DWORD *pdwTimeout,
317 [in] IInternetTransport *pTransport);
319 HRESULT OnLogonPrompt(
320 [in,out] LPINETSERVER pInetServer,
321 [in] IInternetTransport *pTransport);
324 [in] HRESULT hrError,
326 [in] LPCSTR pszCaption,
328 [in] IInternetTransport *pTransport);
331 [in] IXPSTATUS ixpstatus,
332 [in] IInternetTransport *pTransport);
335 [in] IXPSTATUS ixpstatus,
336 [in] LPIXPRESULT pResult,
337 [in] IInternetTransport *pTransport);
340 [in] CMDTYPE cmdtype,
342 [in] HRESULT hrResponse,
343 [in] IInternetTransport *pTransport);
348 uuid(1F636C01-364E-11D0-81D3-00C04FD85AB4),
351interface IInternetTransport : IUnknown
353 const boolean iitAUTHENTICATE = TRUE;
354 const boolean iitDONT_AUTHENTICATe = FALSE;
355 const boolean iitENABLE_ONCOMMAND = TRUE;
356 const boolean iitDISABLE_ONCOMMAND = FALSE;
358 typedef enum tagIXPISSTATE
366 HRESULT GetServerInfo(
367 [in,out] LPINETSERVER pInetServer);
369 IXPTYPE GetIXPType();
372 [in] IXPISSTATE isstate);
374 HRESULT InetServerFromAccount(
375 [in] IImnAccount *pAccount,
376 [in,out] LPINETSERVER pInetServer);
379 [in] LPINETSERVER pInetServer,
380 [in] boolean fAuthenticate,
381 [in] boolean fCommandLogging);
383 HRESULT HandsOffCallback();
385 HRESULT Disconnect();
387 HRESULT DropConnection();
390 [out] IXPSTATUS *pCurrentStatus);
395 uuid(1F636C02-364E-11D0-81D3-00C04FD85AB4),
398interface ISMTPCallback : ITransportCallback
400 typedef enum tagSMTPCOMMAND
419 typedef struct tagSMTPSTREAM
424 } SMTPSTREAM, *LPSMTPSTREAM;
426 typedef struct tagSMTPRESPONSE
430 IXPRESULT rIxpResult;
431 ISMTPTransport *pTransport;
433 [switch_type(SMTPCOMMAND), switch_is(command)]
436 [case(SMTP_SEND_STREAM)] SMTPSTREAM rStreamInfo;
439 } SMTPRESPONSE, *LPSMTPRESPONSE;
442 [in] LPSMTPRESPONSE pResponse);
447 uuid(0DF2C7E2-3435-11D0-81D0-00C04FD85AB4),
450interface ISMTPTransport : IInternetTransport
452 typedef struct tagSMTPMESSAGE
456 INETADDRLIST rAddressList;
457 } SMTPMESSAGE, *LPSMTPMESSAGE;
460 [in] LPSTR pszLogFilePath,
461 [in] ISMTPCallback *pCallback);
463cpp_quote("#ifdef WINE_NO_UNICODE_MACROS")
464cpp_quote("#undef SendMessage")
468 [in] LPSMTPMESSAGE pMessage);
471 [in] LPSTR pszEmailFrom);
474 [in] LPSTR pszEmailTo);
476 HRESULT CommandEHLO();
478 HRESULT CommandHELO();
481 [in] LPSTR pszAuthType);
483 HRESULT CommandQUIT();
485 HRESULT CommandRSET();
487 HRESULT CommandDATA();
489 HRESULT CommandDOT();
491 HRESULT SendDataStream(
492 [in] IStream *pStream,
498 uuid(0DF2C7EC-3435-11D0-81D0-00C04FD85AB4),
501interface ISMTPTransport2 : ISMTPTransport
503 typedef struct tagSMTPMESSAGE2
510 } SMTPMESSAGE2, *LPSMTPMESSAGE2;
514 HRESULT ResetWindow();
516 HRESULT SendMessage2(
517 [in] LPSMTPMESSAGE2 pMessage);
519 HRESULT CommandRCPT2(
520 [in] LPSTR pszEmailTo,
521 [in] INETADDRTYPE atDSN);
524/* FIXME: IDAVNamespaceArbiter, IPropPatchRequest, IPropFindRequest, IPropFindMultiResponse, IPropFindResponse, IHTTPMailCallback, IHTTPMailTransport */
528 uuid(0DF2C7E3-3435-11D0-81D0-00C04FD85AB4),
531interface IPOP3Callback : ITransportCallback
533 typedef enum tagPOP3COMMAND
553 typedef struct tagPOP3RETR
561 } POP3RETR, *LPPOP3RETR;
563 typedef struct tagPOP3TOP
572 } POP3TOP, *LPPOP3TOP;
574 typedef struct tagPOP3LIST
578 } POP3LIST, *LPPOP3LIST;
580 typedef struct tagPOP3UIDL
584 } POP3UIDL, *LPPOP3UIDL;
586 typedef struct tagPOP3STAT
590 } POP3STAT, *LPPOP3STAT;
592 typedef struct tagPOP3RESPONSE
596 IXPRESULT rIxpResult;
597 IPOP3Transport *pTransport;
599 [switch_type(POP3COMMAND), switch_is(command)]
602 [case(POP3_UIDL)] POP3UIDL rUidlInfo;
603 [case(POP3_STAT)] POP3STAT rStatInfo;
604 [case(POP3_LIST)] POP3LIST rListInfo;
605 [case(POP3_DELE)] DWORD dwPopId;
606 [case(POP3_RETR)] POP3RETR rRetrInfo;
607 [case(POP3_TOP)] POP3TOP rTopInfo;
610 } POP3RESPONSE, *LPPOP3RESPONSE;
613 [in] LPPOP3RESPONSE pResponse);
618 uuid(0DF2C7E4-3435-11D0-81D0-00C04FD85AB4),
621interface IPOP3Transport : IInternetTransport
623 typedef enum tagPOP3CMDTYPE
630 typedef enum tagPOP3MARKTYPE
632 POP3_MARK_FOR_TOP = 0x01,
633 POP3_MARK_FOR_RETR = 0x02,
634 POP3_MARK_FOR_DELE = 0x04,
635 POP3_MARK_FOR_UIDL = 0x08,
636 POP3_MARK_FOR_LIST = 0x10
640 [in] LPSTR pszLogFilePath,
641 [in] IPOP3Callback *pCallback);
644 [in] POP3MARKTYPE marktype,
646 [in] boolean fMarked);
649 [in] LPSTR pszAuthType);
652 [in] LPSTR pszUserName);
655 [in] LPSTR pszPassword);
658 [in] POP3CMDTYPE cmdtype,
662 [in] POP3CMDTYPE cmdtype,
664 [in] DWORD cPreviewLines);
666 HRESULT CommandQUIT();
668 HRESULT CommandSTAT();
670 HRESULT CommandNOOP();
672 HRESULT CommandRSET();
675 [in] POP3CMDTYPE cmdtype,
679 [in] POP3CMDTYPE cmdtype,
683 [in] POP3CMDTYPE cmdtype,
687/* FIXME: INNTPCallback, INNTPTransport */
691 uuid(8C438160-4EF6-11d0-874F-00AA00530EE9),
694interface IRangeList : IUnknown
696 const ULONG RL_RANGE_ERROR = ((ULONG)-1);
697 const ULONG RL_LAST_MESSAGE = ((ULONG)-1);
702 [in] const ULONG value);
705 [out] ULONG *pulMin);
708 [out] ULONG *pulMax);
711 [out] byte **ppbDestination,
712 [out] ULONG *pulSizeOfDestination);
715 [in, size_is(ulSizeOfSource)] byte *pbSource,
716 [in] const ULONG ulSizeOfSource);
719 [in] const ULONG low,
720 [in] const ULONG high);
722 HRESULT AddSingleValue(
723 [in] const ULONG value);
725 HRESULT AddRangeList(
726 [in] const IRangeList *prl);
729 [in] const ULONG low,
730 [in] const ULONG high);
732 HRESULT DeleteSingleValue(
733 [in] const ULONG value);
735 HRESULT DeleteRangeList(
736 [in] const IRangeList *prl);
739 [in] const ULONG value,
740 [out] ULONG *pulMinOfRange);
743 [in] const ULONG value,
744 [out] ULONG *pulMaxOfRange);
746 HRESULT RangeToIMAPString(
747 [out] LPSTR *ppszDestination,
748 [out] LPDWORD pdwLengthOfDestination);
751 [in] const ULONG current,
752 [out] ULONG *pulNext);
755 [in] const ULONG current,
756 [out] ULONG *pulPrev);
759 [out] ULONG *pulCardinality);
761 HRESULT CardinalityFrom(
762 [in] const ULONG ulStartPoint,
763 [out] ULONG *pulCardinalityFrom);
768 uuid(E9E9D8A3-4EDD-11d0-874F-00AA00530EE9),
771interface IIMAPCallback : ITransportCallback
773 typedef DWORD IMAP_MBOXFLAGS;
774 const IMAP_MBOXFLAGS IMAP_MBOX_NOFLAGS = 0x0;
775 const IMAP_MBOXFLAGS IMAP_MBOX_MARKED = 0x1;
776 const IMAP_MBOXFLAGS IMAP_MBOX_NOINFERIORS = 0x2;
777 const IMAP_MBOXFLAGS IMAP_MBOX_NOSELECT = 0x4;
778 const IMAP_MBOXFLAGS IMAP_MBOX_UNMARKED = 0x8;
779 const IMAP_MBOXFLAGS IMAP_MBOX_ALLFLAGS = 0xf;
781 typedef enum tagIMAP_RESPONSE_TYPE
783 irtERROR_NOTIFICATION,
784 irtCOMMAND_COMPLETION,
801 } IMAP_RESPONSE_TYPE;
803 typedef struct tagFETCH_BODY_PART
812 LPARAM lpFetchCookie1;
813 LPARAM lpFetchCookie2;
816 typedef struct tagFETCH_CMD_RESULTS
820 IMAP_MSGFLAGS mfMsgFlags;
826 FILETIME ftInternalDate;
827 LPARAM lpFetchCookie1;
828 LPARAM lpFetchCookie2;
831 typedef struct tagIMAPADDR
837 struct tagIMAPADDR *pNext;
840 typedef struct tagFETCH_CMD_RESULTS_EX
844 IMAP_MSGFLAGS mfMsgFlags;
850 FILETIME ftInternalDate;
851 LPARAM lpFetchCookie1;
852 LPARAM lpFetchCookie2;
856 IMAPADDR *piaENVFrom;
857 IMAPADDR *piaENVSender;
858 IMAPADDR *piaENVReplyTo;
862 LPSTR pszENVInReplyTo;
863 LPSTR pszENVMessageID;
867 } FETCH_CMD_RESULTS_EX;
869 typedef struct tagMBOX_MSGCOUNT
871 BOOL bGotExistsResponse;
873 BOOL bGotRecentResponse;
875 BOOL bGotUnseenResponse;
879 typedef struct tagIMAP_LISTLSUB_RESPONSE
881 LPSTR pszMailboxName;
882 IMAP_MBOXFLAGS imfMboxFlags;
884 } IMAP_LISTLSUB_RESPONSE;
886 typedef struct tagIMAP_STATUS_RESPONSE
888 LPSTR pszMailboxName;
899 } IMAP_STATUS_RESPONSE;
901 typedef struct tagAPPEND_PROGRESS
907 typedef [switch_type(IMAP_RESPONSE_TYPE)] union tagIMAP_RESPONSE_DATA
909 [case (irtMAILBOX_UPDATE)] MBOX_MSGCOUNT *pmcMsgCount;
910 [case (irtDELETED_MSG)] DWORD dwDeletedMsgSeqNum;
911 [case (irtFETCH_BODY)] FETCH_BODY_PART *pFetchBodyPart;
912 [case (irtUPDATE_MSG)] FETCH_CMD_RESULTS *pFetchResults;
913 [case (irtAPPLICABLE_FLAGS, irtPERMANENT_FLAGS)] IMAP_MSGFLAGS imfImapMessageFlags;
914 [case (irtUIDVALIDITY)] DWORD dwUIDValidity;
915 [case (irtREADWRITE_STATUS)] BOOL bReadWrite;
916 [case (irtSEARCH)] IRangeList *prlSearchResults;
917 [case (irtMAILBOX_LISTING)] IMAP_LISTLSUB_RESPONSE illrdMailboxListing;
918 [case (irtMAILBOX_STATUS)] IMAP_STATUS_RESPONSE *pisrStatusResponse;
919 [case (irtAPPEND_PROGRESS)] APPEND_PROGRESS *papAppendProgress;
920 [case (irtUPDATE_MSG_EX)] FETCH_CMD_RESULTS_EX *pFetchResultsEx;
921 } IMAP_RESPONSE_DATA;
923 typedef struct tagIMAP_RESPONSE
928 LPSTR lpszResponseText;
929 IMAP_RESPONSE_TYPE irtResponseType;
930 [switch_is(irtResponseType)] IMAP_RESPONSE_DATA irdResponseData;
933 HRESULT OnResponse([in] const IMAP_RESPONSE *pirIMAPResponse);
938uuid(E9E9D8A8-4EDD-11d0-874F-00AA00530EE9),
941interface IIMAPTransport : IInternetTransport
943 const DWORD IMAP_CAPABILITY_IMAP4 = 0x1;
944 const DWORD IMAP_CAPABILITY_IMAP4rev1 = 0x2;
945 const DWORD IMAP_CAPABILITY_IDLE = 0x4;
946 const DWORD IMAP_CAPABILITY_ALLFLAGS = 0x7;
949 [in] LPSTR pszLogFilePath,
950 [in] IIMAPCallback *pCBHandler);
952 HRESULT NewIRangeList(
953 [out] IRangeList **pprlNewRangeList);
956 [out] DWORD *pdwCapabilityFlags);
961 [in] IIMAPCallback *pCBHandler,
962 [in] LPSTR lpszMailboxName);
967 [in] IIMAPCallback *pCBHandler,
968 [in] LPSTR lpszMailboxName);
973 [in] IIMAPCallback *pCBHandler,
974 [in] LPSTR lpszMailboxName);
979 [in] IIMAPCallback *pCBHandler,
980 [in] LPSTR lpszMailboxName);
985 [in] IIMAPCallback *pCBHandler,
986 [in] LPSTR lpszMailboxName,
987 [in] LPSTR lpszNewMailboxName);
992 [in] IIMAPCallback *pCBHandler,
993 [in] LPSTR lpszMailboxName);
998 [in] IIMAPCallback *pCBHandler,
999 [in] LPSTR lpszMailboxName);
1004 [in] IIMAPCallback *pCBHandler,
1005 [in] LPSTR lpszMailboxNameReference,
1006 [in] LPSTR lpszMailboxNamePattern);
1011 [in] IIMAPCallback *pCBHandler,
1012 [in] LPSTR lpszMailboxNameReference,
1013 [in] LPSTR lpszMailboxNamePattern);
1018 [in] IIMAPCallback *pCBHandler,
1019 [in] LPSTR lpszMailboxName,
1020 [in] LPSTR lpszMessageFlags,
1021 [in] FILETIME ftMessageDateTime,
1022 [in] LPSTREAM lpstmMessageToSave);
1027 [in] IIMAPCallback *pCBHandler);
1032 [in] IIMAPCallback *pCBHandler);
1037 [in] IIMAPCallback *pCBHandler,
1038 [in] LPSTR lpszSearchCriteria,
1039 [in] boolean bReturnUIDs,
1040 [in] IRangeList *pMsgRange,
1041 [in] boolean bUIDRangeList);
1046 [in] IIMAPCallback *pCBHandler,
1047 [in] IRangeList *pMsgRange,
1048 [in] boolean bUIDMsgRange,
1049 [in] LPSTR lpszFetchArgs);
1054 [in] IIMAPCallback *pCBHandler,
1055 [in] IRangeList *pMsgRange,
1056 [in] boolean bUIDRangeList,
1057 [in] LPSTR lpszStoreArgs);
1062 [in] IIMAPCallback *pCBHandler,
1063 [in] IRangeList *pMsgRange,
1064 [in] boolean bUIDRangeList,
1065 [in] LPSTR lpszMailboxName);
1070 [in] IIMAPCallback *pCBHandler);
1072 HRESULT ResizeMsgSeqNumTable(
1073 [in] DWORD dwSizeOfMbox);
1075 HRESULT UpdateSeqNumToUID(
1076 [in] DWORD dwMsgSeqNum,
1079 HRESULT RemoveSequenceNum(
1080 [in] DWORD dwDeletedMsgSeqNum);
1082 HRESULT MsgSeqNumToUID(
1083 [in] DWORD dwMsgSeqNum,
1084 [out] DWORD *pdwUID);
1086 HRESULT GetMsgSeqNumToUIDArray(
1087 [out] DWORD **ppdwMsgSeqNumToUIDArray,
1088 [out] DWORD *pdwNumberOfElements);
1090 HRESULT GetHighestMsgSeqNum(
1091 [out] DWORD *pdwHighestMSN);
1093 HRESULT ResetMsgSeqNumToUID();
1095 HRESULT SetDefaultCBHandler(
1096 [in] IIMAPCallback *pCBHandler);
1101 [in] IIMAPCallback *pCBHandler,
1102 [in] LPSTR pszMailboxName,
1103 [in] LPSTR pszStatusCmdArgs);
1107cpp_quote("HRESULT WINAPI CreateRASTransport(IRASTransport **ppTransport);")
1108cpp_quote("HRESULT WINAPI CreateNNTPTransport(INNTPTransport **ppTransport);")
1109cpp_quote("HRESULT WINAPI CreateIMAPTransport2(IIMAPTransport2 **ppTransport);")
1111cpp_quote("HRESULT WINAPI CreateRangeList(IRangeList **ppRangeList);")
1112cpp_quote("HRESULT WINAPI CreateSMTPTransport(ISMTPTransport **ppTransport);")
1113cpp_quote("HRESULT WINAPI CreatePOP3Transport(IPOP3Transport **ppTransport);")
1114cpp_quote("HRESULT WINAPI CreateIMAPTransport(IIMAPTransport **ppTransport);")
CD3D10_BUFFER_DESC D3D10_BUFFER_DESC cpp_quote(" ~CD3D10_BUFFER_DESC() {}") operator const D3D10_BUFFER_DESC &() const
#define DEFINE_GUID(name, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8)