ReactOS 0.4.15-dev-7953-g1f49173
mapi.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2000 Francois Gouget
3 *
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.
8 *
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.
13 *
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
17 */
18
19#ifndef MAPI_H
20#define MAPI_H
21
22#ifdef __cplusplus
23extern "C" {
24#endif
25
26/* Some types */
27
28#ifndef __LHANDLE
29#define __LHANDLE
31#endif
32#define lhSessionNull ((LHANDLE)0)
33
34#ifndef WINE_FLAGS_DEFINED
35#define WINE_FLAGS_DEFINED
36typedef ULONG FLAGS;
37#endif
38typedef ULONG *LPULONG;
39
40typedef struct
41{
49
50typedef struct
51{
59
60#ifndef MAPI_ORIG
61#define MAPI_ORIG 0
62#define MAPI_TO 1
63#define MAPI_CC 2
64#define MAPI_BCC 3
65#endif
66
67typedef struct
68{
76
77typedef struct
78{
86
87typedef struct
88{
102
103typedef struct
104{
118
119/* Error codes */
120
121#ifndef SUCCESS_SUCCESS
122#define SUCCESS_SUCCESS 0
123#endif
124
125#define MAPI_USER_ABORT 1
126#define MAPI_E_USER_ABORT MAPI_USER_ABORT
127#define MAPI_E_FAILURE 2
128#define MAPI_E_LOGON_FAILURE 3
129#define MAPI_E_LOGIN_FAILURE MAPI_E_LOGON_FAILURE
130#define MAPI_E_DISK_FULL 4
131#define MAPI_E_INSUFFICIENT_MEMORY 5
132#define MAPI_E_ACCESS_DENIED 6
133#define MAPI_E_TOO_MANY_SESSIONS 8
134#define MAPI_E_TOO_MANY_FILES 9
135#define MAPI_E_TOO_MANY_RECIPIENTS 10
136#define MAPI_E_ATTACHMENT_NOT_FOUND 11
137#define MAPI_E_ATTACHMENT_OPEN_FAILURE 12
138#define MAPI_E_ATTACHMENT_WRITE_FAILURE 13
139#define MAPI_E_UNKNOWN_RECIPIENT 14
140#define MAPI_E_BAD_RECIPTYPE 15
141#define MAPI_E_NO_MESSAGES 16
142#define MAPI_E_INVALID_MESSAGE 17
143#define MAPI_E_TEXT_TOO_LARGE 18
144#define MAPI_E_INVALID_SESSION 19
145#define MAPI_E_TYPE_NOT_SUPPORTED 20
146#define MAPI_E_AMBIGUOUS_RECIPIENT 21
147#define MAPI_E_AMBIG_RECIP MAPI_E_AMBIGUOUS_RECIPIENT
148#define MAPI_E_MESSAGE_IN_USE 22
149#define MAPI_E_NETWORK_FAILURE 23
150#define MAPI_E_INVALID_EDITFIELDS 24
151#define MAPI_E_INVALID_RECIPS 25
152#define MAPI_E_NOT_SUPPORTED 26
153#define MAPI_E_UNICODE_NOT_SUPPORTED 27
154
155
156/* MAPILogon */
157
158#ifndef MAPI_LOGON_UI
159#define MAPI_LOGON_UI 0x00000001
160#endif
161#ifndef MAPI_NEW_SESSION
162#define MAPI_NEW_SESSION 0x00000002
163#endif
164#ifndef MAPI_EXTENDED
165#define MAPI_EXTENDED 0x00000020
166#endif
167#ifndef MAPI_FORCE_DOWNLOAD
168#define MAPI_FORCE_DOWNLOAD 0x00001000
169#endif
170#ifndef MAPI_PASSWORD_UI
171#define MAPI_PASSWORD_UI 0x00020000
172#endif
173
174
175/* MAPISendMail */
176
177#define MAPI_DIALOG 0x00000008
178
179/* MAPISendMailW */
180
181#define MAPI_FORCE_UNICODE 0x00040000
182
183
184/* API typedefs and prototypes */
185
187typedef MAPIADDRESS *LPMAPIADDRESS;
188MAPIADDRESS MAPIAddress;
189
190typedef ULONG (WINAPI MAPIDELETEMAIL)(LHANDLE,ULONG_PTR,LPSTR,FLAGS,ULONG);
191typedef MAPIDELETEMAIL *LPMAPIDELETEMAIL;
192MAPIDELETEMAIL MAPIDeleteMail;
193
195typedef MAPIDETAILS *LPMAPIDETAILS;
196MAPIDETAILS MAPIDetails;
197
198typedef ULONG (WINAPI MAPIFINDNEXT)(LHANDLE,ULONG_PTR,LPSTR,LPSTR,FLAGS,ULONG,LPSTR);
199typedef MAPIFINDNEXT *LPMAPIFINDNEXT;
200MAPIFINDNEXT MAPIFindNext;
201
202#ifndef MAPIFREEBUFFER_DEFINED
203#define MAPIFREEBUFFER_DEFINED
204typedef ULONG (WINAPI MAPIFREEBUFFER)(LPVOID);
205typedef MAPIFREEBUFFER *LPMAPIFREEBUFFER;
206MAPIFREEBUFFER MAPIFreeBuffer;
207#endif
208
209typedef ULONG (WINAPI MAPILOGOFF)(LHANDLE,ULONG_PTR,FLAGS,ULONG);
210typedef MAPILOGOFF *LPMAPILOGOFF;
211MAPILOGOFF MAPILogoff;
212
213typedef ULONG (WINAPI MAPILOGON)(ULONG_PTR,LPSTR,LPSTR,FLAGS,ULONG,LPLHANDLE);
214typedef MAPILOGON *LPMAPILOGON;
215MAPILOGON MAPILogon;
216
218typedef MAPIREADMAIL *LPMAPIREADMAIL;
219MAPIREADMAIL MAPIReadMail;
220
221typedef ULONG (WINAPI MAPIRESOLVENAME)(LHANDLE,ULONG_PTR,LPSTR,FLAGS,ULONG,lpMapiRecipDesc*);
222typedef MAPIRESOLVENAME *LPMAPIRESOLVENAME;
223MAPIRESOLVENAME MAPIResolveName;
224
226typedef MAPISAVEMAIL *LPMAPISAVEMAIL;
227MAPISAVEMAIL MAPISaveMail;
228
229typedef ULONG (WINAPI MAPISENDDOCUMENTS)(ULONG_PTR,LPSTR,LPSTR,LPSTR,ULONG);
230typedef MAPISENDDOCUMENTS *LPMAPISENDDOCUMENTS;
231MAPISENDDOCUMENTS MAPISendDocuments;
232
233typedef ULONG (WINAPI MAPISENDMAIL)(LHANDLE,ULONG_PTR,lpMapiMessage,FLAGS,ULONG);
234typedef MAPISENDMAIL *LPMAPISENDMAIL;
235MAPISENDMAIL MAPISendMail;
236
238typedef MAPISENDMAILW *LPMAPISENDMAILW;
239MAPISENDMAILW MAPISendMailW;
240
241#ifdef __cplusplus
242}
243#endif
244
245#endif /* MAPI_H */
MAPILOGON MAPILogon
Definition: mapi.h:215
MAPIFINDNEXT * LPMAPIFINDNEXT
Definition: mapi.h:199
MAPIREADMAIL MAPIReadMail
Definition: mapi.h:219
struct MapiFileDescW * lpMapiFileDescW
MAPIADDRESS MAPIAddress
Definition: mapi.h:188
struct MapiRecipDescW * lpMapiRecipDescW
struct MapiRecipDesc * lpMapiRecipDesc
Definition: mapi.h:186
MAPILOGOFF MAPILogoff
Definition: mapi.h:211
typedef LPSTR
Definition: mapi.h:186
MAPIDELETEMAIL * LPMAPIDELETEMAIL
Definition: mapi.h:191
struct MapiFileDesc * lpMapiFileDesc
MAPIDETAILS MAPIDetails
Definition: mapi.h:196
lpMapiRecipDesc *typedef MAPIRESOLVENAME * LPMAPIRESOLVENAME
Definition: mapi.h:222
MAPISENDMAILW * LPMAPISENDMAILW
Definition: mapi.h:238
MAPIRESOLVENAME MAPIResolveName
Definition: mapi.h:223
MAPIDETAILS * LPMAPIDETAILS
Definition: mapi.h:195
MAPIFREEBUFFER * LPMAPIFREEBUFFER
Definition: mapi.h:205
MAPISENDDOCUMENTS MAPISendDocuments
Definition: mapi.h:231
MAPISENDMAIL * LPMAPISENDMAIL
Definition: mapi.h:234
MAPISENDMAILW MAPISendMailW
Definition: mapi.h:239
MAPIREADMAIL * LPMAPIREADMAIL
Definition: mapi.h:218
lpMapiRecipDesc *typedef MAPIADDRESS * LPMAPIADDRESS
Definition: mapi.h:187
MAPILOGON * LPMAPILOGON
Definition: mapi.h:214
MAPISAVEMAIL * LPMAPISAVEMAIL
Definition: mapi.h:226
MAPILOGOFF * LPMAPILOGOFF
Definition: mapi.h:210
struct MapiMessageW * lpMapiMessageW
Definition: mapi.h:237
MAPIDELETEMAIL MAPIDeleteMail
Definition: mapi.h:192
MAPISAVEMAIL MAPISaveMail
Definition: mapi.h:227
struct MapiMessage * lpMapiMessage
Definition: mapi.h:217
ULONG_PTR LHANDLE
Definition: mapi.h:30
MAPISENDMAIL MAPISendMail
Definition: mapi.h:235
typedef ULONG_PTR
Definition: mapi.h:186
ULONG * LPULONG
Definition: mapi.h:38
MAPISENDDOCUMENTS * LPMAPISENDDOCUMENTS
Definition: mapi.h:230
ULONG FLAGS
Definition: mapi.h:36
ULONG_PTR * LPLHANDLE
Definition: mapi.h:30
typedef ULONG
Definition: mapi.h:186
MAPIFREEBUFFER MAPIFreeBuffer
Definition: mapi.h:206
MAPIFINDNEXT MAPIFindNext
Definition: mapi.h:200
#define LPVOID
Definition: nt_native.h:45
ULONG flFlags
Definition: mapi.h:53
ULONG ulReserved
Definition: mapi.h:52
ULONG nPosition
Definition: mapi.h:54
PVOID lpFileType
Definition: mapi.h:57
PWSTR lpszPathName
Definition: mapi.h:55
PWSTR lpszFileName
Definition: mapi.h:56
LPVOID lpFileType
Definition: mapi.h:47
ULONG nPosition
Definition: mapi.h:44
LPSTR lpszPathName
Definition: mapi.h:45
LPSTR lpszFileName
Definition: mapi.h:46
ULONG ulReserved
Definition: mapi.h:42
ULONG flFlags
Definition: mapi.h:43
lpMapiRecipDescW lpRecips
Definition: mapi.h:114
PWSTR lpszDateReceived
Definition: mapi.h:109
lpMapiRecipDescW lpOriginator
Definition: mapi.h:112
PWSTR lpszMessageType
Definition: mapi.h:108
ULONG nFileCount
Definition: mapi.h:115
lpMapiFileDescW lpFiles
Definition: mapi.h:116
ULONG nRecipCount
Definition: mapi.h:113
PWSTR lpszNoteText
Definition: mapi.h:107
PWSTR lpszConversationID
Definition: mapi.h:110
ULONG ulReserved
Definition: mapi.h:105
PWSTR lpszSubject
Definition: mapi.h:106
FLAGS flFlags
Definition: mapi.h:111
lpMapiRecipDesc lpRecips
Definition: mapi.h:98
LPSTR lpszDateReceived
Definition: mapi.h:93
LPSTR lpszNoteText
Definition: mapi.h:91
FLAGS flFlags
Definition: mapi.h:95
ULONG nFileCount
Definition: mapi.h:99
LPSTR lpszSubject
Definition: mapi.h:90
ULONG ulReserved
Definition: mapi.h:89
LPSTR lpszMessageType
Definition: mapi.h:92
LPSTR lpszConversationID
Definition: mapi.h:94
lpMapiRecipDesc lpOriginator
Definition: mapi.h:96
ULONG nRecipCount
Definition: mapi.h:97
lpMapiFileDesc lpFiles
Definition: mapi.h:100
PVOID lpEntryID
Definition: mapi.h:84
ULONG ulRecipClass
Definition: mapi.h:80
ULONG ulReserved
Definition: mapi.h:79
ULONG ulEIDSize
Definition: mapi.h:83
PWSTR lpszName
Definition: mapi.h:81
PWSTR lpszAddress
Definition: mapi.h:82
ULONG ulRecipClass
Definition: mapi.h:70
ULONG ulEIDSize
Definition: mapi.h:73
LPVOID lpEntryID
Definition: mapi.h:74
LPSTR lpszName
Definition: mapi.h:71
LPSTR lpszAddress
Definition: mapi.h:72
ULONG ulReserved
Definition: mapi.h:69
uint16_t * PWSTR
Definition: typedefs.h:56
uint32_t ULONG_PTR
Definition: typedefs.h:65
uint32_t ULONG
Definition: typedefs.h:59
#define WINAPI
Definition: msvc.h:6
char * LPSTR
Definition: xmlstorage.h:182