ReactOS  0.4.15-dev-2776-g4130f0b
xcmc.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2004 Chris Morgan
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 Street, Fifth Floor, Boston, MA 02110-1301 USA
17  */
18 
19 #ifndef _XCMC_H
20 #define _XCMC_H
21 
22 #ifdef __cplusplus
23 extern "C" {
24 #endif
25 
26 typedef char CMC_sint8;
27 typedef short CMC_sint16;
28 typedef long int CMC_sint32;
29 typedef unsigned short int CMC_uint16;
30 typedef unsigned long int CMC_uint32;
31 typedef void* CMC_buffer;
32 typedef char* CMC_string;
33 
41 
42 #define CMC_FALSE ((CMC_boolean)0)
43 #define CMC_TRUE ((CMC_boolean)1)
44 
45 #define CMC_SUCCESS ((CMC_return_code) 0)
46 
47 #define CMC_E_AMBIGUOUS_RECIPIENT ((CMC_return_code) 1)
48 #define CMC_E_ATTACHMENT_NOT_FOUND ((CMC_return_code) 2)
49 #define CMC_E_ATTACHMENT_OPEN_FAILURE ((CMC_return_code) 3)
50 #define CMC_E_ATTACHMENT_READ_FAILURE ((CMC_return_code) 4)
51 #define CMC_E_ATTACHMENT_WRITE_FAILURE ((CMC_return_code) 5)
52 #define CMC_E_COUNTED_STRING_UNSUPPORTED ((CMC_return_code) 6)
53 #define CMC_E_DISK_FULL ((CMC_return_code) 7)
54 #define CMC_E_FAILURE ((CMC_return_code) 8)
55 #define CMC_E_INSUFFICIENT_MEMORY ((CMC_return_code) 9)
56 #define CMC_E_INVALID_CONFIGURATION ((CMC_return_code) 10)
57 #define CMC_E_INVALID_ENUM ((CMC_return_code) 11)
58 #define CMC_E_INVALID_FLAG ((CMC_return_code) 12)
59 #define CMC_E_INVALID_MEMORY ((CMC_return_code) 13)
60 #define CMC_E_INVALID_MESSAGE_PARAMETER ((CMC_return_code) 14)
61 #define CMC_E_INVALID_MESSAGE_REFERENCE ((CMC_return_code) 15)
62 #define CMC_E_INVALID_PARAMETER ((CMC_return_code) 16)
63 #define CMC_E_INVALID_SESSION_ID ((CMC_return_code) 17)
64 #define CMC_E_INVALID_UI_ID ((CMC_return_code) 18)
65 #define CMC_E_LOGON_FAILURE ((CMC_return_code) 19)
66 #define CMC_E_MESSAGE_IN_USE ((CMC_return_code) 20)
67 #define CMC_E_NOT_SUPPORTED ((CMC_return_code) 21)
68 #define CMC_E_PASSWORD_REQUIRED ((CMC_return_code) 22)
69 #define CMC_E_RECIPIENT_NOT_FOUND ((CMC_return_code) 23)
70 #define CMC_E_SERVICE_UNAVAILABLE ((CMC_return_code) 24)
71 #define CMC_E_TEXT_TOO_LARGE ((CMC_return_code) 25)
72 #define CMC_E_TOO_MANY_FILES ((CMC_return_code) 26)
73 #define CMC_E_TOO_MANY_RECIPIENTS ((CMC_return_code) 27)
74 #define CMC_E_UNABLE_TO_NOT_MARK_AS_READ ((CMC_return_code) 28)
75 #define CMC_E_UNRECOGNIZED_MESSAGE_TYPE ((CMC_return_code) 29)
76 #define CMC_E_UNSUPPORTED_ACTION ((CMC_return_code) 30)
77 #define CMC_E_UNSUPPORTED_CHARACTER_SET ((CMC_return_code) 31)
78 #define CMC_E_UNSUPPORTED_DATA_EXT ((CMC_return_code) 32)
79 #define CMC_E_UNSUPPORTED_FLAG ((CMC_return_code) 33)
80 #define CMC_E_UNSUPPORTED_FUNCTION_EXT ((CMC_return_code) 34)
81 #define CMC_E_UNSUPPORTED_VERSION ((CMC_return_code) 35)
82 #define CMC_E_USER_CANCEL ((CMC_return_code) 36)
83 #define CMC_E_USER_NOT_LOGGED_ON ((CMC_return_code) 37)
84 
85 #define CMC_ERROR_DISPLAYED ((CMC_return_code) 0x00008000)
86 #define CMC_ERROR_RSV_MASK ((CMC_return_code) 0x0000FFFF)
87 #define CMC_ERROR_IMPL_MASK ((CMC_return_code) 0xFFFF0000)
88 
89 typedef struct {
91  char string[1];
93 
95 
96 typedef struct {
107 } CMC_time;
108 
109 #define CMC_NO_TIMEZONE ((CMC_sint16) 0x8000)
110 
111 
112 typedef struct {
117 } CMC_extension;
118 
119 #define CMC_EXT_REQUIRED ((CMC_flags) 0x00010000)
120 #define CMC_EXT_OUTPUT ((CMC_flags) 0x00020000)
121 #define CMC_EXT_LAST_ELEMENT ((CMC_flags) 0x80000000)
122 #define CMC_EXT_RSV_FLAG_MASK ((CMC_flags) 0xFFFF0000)
123 #define CMC_EXT_ITEM_FLAG_MASK ((CMC_flags) 0x0000FFFF)
124 
125 
126 typedef struct CMC_attachment_s {
133 
134 #define CMC_ATT_APP_OWNS_FILE ((CMC_flags) 1)
135 #define CMC_ATT_LAST_ELEMENT ((CMC_flags) 0x80000000)
136 
137 #define CMC_ATT_OID_BINARY "? ? ? ? ? ?"
138 #define CMC_ATT_OID_TEXT "? ? ? ? ? ?"
139 
140 
141 typedef struct {
148 } CMC_recipient;
149 
150 #define CMC_TYPE_UNKNOWN ((CMC_enum) 0)
151 #define CMC_TYPE_INDIVIDUAL ((CMC_enum) 1)
152 #define CMC_TYPE_GROUP ((CMC_enum) 2)
153 
154 #define CMC_ROLE_TO ((CMC_enum) 0)
155 #define CMC_ROLE_CC ((CMC_enum) 1)
156 #define CMC_ROLE_BCC ((CMC_enum) 2)
157 #define CMC_ROLE_ORIGINATOR ((CMC_enum) 3)
158 #define CMC_ROLE_AUTHORIZING_USER ((CMC_enum) 4)
159 
160 #define CMC_RECIP_IGNORE ((CMC_flags) 1)
161 #define CMC_RECIP_LIST_TRUNCATED ((CMC_flags) 2)
162 #define CMC_RECIP_LAST_ELEMENT ((CMC_flags) 0x80000000)
163 
164 
165 typedef struct {
175 } CMC_message;
176 
177 #define CMC_MSG_READ ((CMC_flags) 1)
178 #define CMC_MSG_TEXT_NOTE_AS_FILE ((CMC_flags) 2)
179 #define CMC_MSG_UNSENT ((CMC_flags) 4)
180 #define CMC_MSG_LAST_ELEMENT ((CMC_flags) 0x80000000)
181 
182 
183 typedef struct {
193 
194 #define CMC_SUM_READ ((CMC_flags) 1)
195 #define CMC_SUM_UNSENT ((CMC_flags) 2)
196 #define CMC_SUM_LAST_ELEMENT ((CMC_flags) 0x80000000)
197 
198 #define CMC_ERROR_UI_ALLOWED ((CMC_flags) 0x01000000)
199 #define CMC_LOGON_UI_ALLOWED ((CMC_flags) 0x02000000)
200 #define CMC_COUNTED_STRING_TYPE ((CMC_flags) 0x04000000)
201 
205  CMC_flags send_flags,
206  CMC_ui_id ui_id,
207  CMC_extension *send_extensions
208 );
209 
210 #define CMC_SEND_UI_REQUESTED ((CMC_flags) 1)
211 
212 
214  CMC_string recipient_addresses,
215  CMC_string subject,
216  CMC_string text_note,
217  CMC_flags send_doc_flags,
218  CMC_string file_paths,
219  CMC_string file_names,
221  CMC_ui_id ui_id
222 );
223 
224 #define CMC_FIRST_ATTACH_AS_TEXT_NOTE ((CMC_flags) 2)
225 
226 
229  CMC_message_reference *message_reference,
230  CMC_enum operation,
231  CMC_flags act_on_flags,
232  CMC_ui_id ui_id,
233  CMC_extension *act_on_extensions
234 );
235 
236 #define CMC_ACT_ON_EXTENDED ((CMC_enum) 0)
237 #define CMC_ACT_ON_DELETE ((CMC_enum) 1)
238 
239 
242  CMC_string message_type,
243  CMC_flags list_flags,
244  CMC_message_reference *seed,
245  CMC_uint32 *count,
246  CMC_ui_id ui_id,
248  CMC_extension *list_extensions
249 );
250 
251 #define CMC_LIST_UNREAD_ONLY ((CMC_flags) 1)
252 #define CMC_LIST_MSG_REFS_ONLY ((CMC_flags) 2)
253 #define CMC_LIST_COUNT_ONLY ((CMC_flags) 4)
254 
255 #define CMC_LENGTH_UNKNOWN 0xFFFFFFFF
256 
257 
260  CMC_message_reference *message_reference,
261  CMC_flags read_flags,
263  CMC_ui_id ui_id,
264  CMC_extension *read_extensions
265 );
266 
267 #define CMC_DO_NOT_MARK_AS_READ ((CMC_flags) 1)
268 #define CMC_MSG_AND_ATT_HDRS_ONLY ((CMC_flags) 2)
269 #define CMC_READ_FIRST_UNREAD_MESSAGE ((CMC_flags) 4)
270 
271 
274  CMC_recipient *recipient_in,
275  CMC_flags look_up_flags,
276  CMC_ui_id ui_id,
277  CMC_uint32 *count,
278  CMC_recipient **recipient_out,
279  CMC_extension *look_up_extensions
280 );
281 
282 #define CMC_LOOKUP_RESOLVE_PREFIX_SEARCH ((CMC_flags) 1)
283 #define CMC_LOOKUP_RESOLVE_IDENTITY ((CMC_flags) 2)
284 #define CMC_LOOKUP_RESOLVE_UI ((CMC_flags) 4)
285 #define CMC_LOOKUP_DETAILS_UI ((CMC_flags) 8)
286 #define CMC_LOOKUP_ADDRESSING_UI ((CMC_flags) 16)
287 
288 
290 
293  CMC_ui_id ui_id,
294  CMC_flags logoff_flags,
295  CMC_extension *logoff_extensions
296 );
297 
299  CMC_string service,
302  CMC_object_identifier character_set,
303  CMC_ui_id ui_id,
304  CMC_uint16 caller_cmc_version,
305  CMC_flags logon_flags,
307  CMC_extension *logon_extensions
308 );
309 
310 #define CMC_VERSION ((CMC_uint16) 100)
311 
314  CMC_enum item,
316  CMC_extension *config_extensions
317 );
318 
319 #define CMC_CONFIG_CHARACTER_SET ((CMC_enum) 1)
320 #define CMC_CONFIG_LINE_TERM ((CMC_enum) 2)
321 #define CMC_CONFIG_DEFAULT_SERVICE ((CMC_enum) 3)
322 #define CMC_CONFIG_DEFAULT_USER ((CMC_enum) 4)
323 #define CMC_CONFIG_REQ_PASSWORD ((CMC_enum) 5)
324 #define CMC_CONFIG_REQ_SERVICE ((CMC_enum) 6)
325 #define CMC_CONFIG_REQ_USER ((CMC_enum) 7)
326 #define CMC_CONFIG_UI_AVAIL ((CMC_enum) 8)
327 #define CMC_CONFIG_SUP_NOMKMSGREAD ((CMC_enum) 9)
328 #define CMC_CONFIG_SUP_COUNTED_STR ((CMC_enum) 10)
329 #define CMC_CONFIG_VER_IMPLEM ((CMC_enum) 11)
330 #define CMC_CONFIG_VER_SPEC ((CMC_enum) 12)
331 
332 #define CMC_LINE_TERM_CRLF ((CMC_enum) 0)
333 #define CMC_LINE_TERM_CR ((CMC_enum) 1)
334 #define CMC_LINE_TERM_LF ((CMC_enum) 2)
335 
336 #define CMC_REQUIRED_NO ((CMC_enum) 0)
337 #define CMC_REQUIRED_YES ((CMC_enum) 1)
338 #define CMC_REQUIRED_OPT ((CMC_enum) 2)
339 
340 #define CMC_CHAR_CP437 "1 2 840 113556 3 2 437"
341 #define CMC_CHAR_CP850 "1 2 840 113556 3 2 85"
342 #define CMC_CHAR_CP1252 "1 2 840 113556 3 2 1252"
343 #define CMC_CHAR_ISTRING "1 2 840 113556 3 2 0"
344 #define CMC_CHAR_UNICODE "1 2 840 113556 3 2 1"
345 
346 #ifdef __cplusplus
347 }
348 #endif
349 
350 #endif /* #ifndef _XCMC_H */
CMC_extension * message_summary_extensions
Definition: xcmc.h:191
CMC_uint32 CMC_flags
Definition: xcmc.h:37
CMC_buffer item_reference
Definition: xcmc.h:115
Definition: tftpd.h:59
CMC_message_reference * message_reference
Definition: xcmc.h:184
GLuint64EXT * result
Definition: glext.h:11304
CMC_flags recip_flags
Definition: xcmc.h:146
GLuint GLuint GLsizei count
Definition: gl.h:1545
CMC_sint8 day
Definition: xcmc.h:100
CMC_return_code WINAPI cmc_send(CMC_session_id session, CMC_message *message, CMC_flags send_flags, CMC_ui_id ui_id, CMC_extension *send_extensions)
CMC_flags attach_flags
Definition: xcmc.h:130
Definition: xcmc.h:96
CMC_string attach_filename
Definition: xcmc.h:129
CMC_flags message_flags
Definition: xcmc.h:173
CMC_string address
Definition: xcmc.h:144
void * CMC_buffer
Definition: xcmc.h:31
char * CMC_string
Definition: xcmc.h:32
CMC_string text_note
Definition: xcmc.h:170
CMC_return_code WINAPI cmc_query_configuration(CMC_session_id session, CMC_enum item, CMC_buffer reference, CMC_extension *config_extensions)
Definition: util.c:849
static char memory[1024 *256]
Definition: process.c:116
CMC_uint32 CMC_session_id
Definition: xcmc.h:39
CMC_uint16 CMC_boolean
Definition: xcmc.h:34
CMC_recipient * originator
Definition: xcmc.h:189
CMC_uint32 item_data
Definition: xcmc.h:114
CMC_string CMC_object_identifier
Definition: xcmc.h:38
CMC_string subject
Definition: xcmc.h:186
CMC_sint8 month
Definition: xcmc.h:101
const char * delimiter
Definition: string.c:1566
CMC_sint32 CMC_enum
Definition: xcmc.h:35
CMC_flags extension_flags
Definition: xcmc.h:116
CMC_return_code WINAPI cmc_read(CMC_session_id session, CMC_message_reference *message_reference, CMC_flags read_flags, CMC_message **message, CMC_ui_id ui_id, CMC_extension *read_extensions)
CMC_flags summary_flags
Definition: xcmc.h:190
CMC_extension * attach_extensions
Definition: xcmc.h:131
CMC_return_code WINAPI cmc_look_up(CMC_session_id session, CMC_recipient *recipient_in, CMC_flags look_up_flags, CMC_ui_id ui_id, CMC_uint32 *count, CMC_recipient **recipient_out, CMC_extension *look_up_extensions)
CMC_uint32 item_code
Definition: xcmc.h:113
unsigned short int CMC_uint16
Definition: xcmc.h:29
CMC_uint32 CMC_return_code
Definition: xcmc.h:36
CMC_time time_sent
Definition: xcmc.h:187
CMC_sint8 hour
Definition: xcmc.h:99
#define WINAPI
Definition: msvc.h:6
CMC_sint8 year
Definition: xcmc.h:102
T1_FIELD_DICT_PRIVATE password
Definition: t1tokens.h:64
CMC_time time_sent
Definition: xcmc.h:169
CMC_sint16 tmzone
Definition: xcmc.h:105
GLint reference
Definition: glext.h:11729
CMC_sint8 minute
Definition: xcmc.h:98
CMC_string message_type
Definition: xcmc.h:185
CMC_return_code WINAPI cmc_act_on(CMC_session_id session, CMC_message_reference *message_reference, CMC_enum operation, CMC_flags act_on_flags, CMC_ui_id ui_id, CMC_extension *act_on_extensions)
CMC_recipient * recipients
Definition: xcmc.h:171
unsigned long int CMC_uint32
Definition: xcmc.h:30
CMC_sint8 isdst
Definition: xcmc.h:103
static ATOM item
Definition: dde.c:856
CMC_extension * message_extensions
Definition: xcmc.h:174
CMC_enum name_type
Definition: xcmc.h:143
struct CMC_attachment_s CMC_attachment
CMC_return_code WINAPI cmc_send_documents(CMC_string recipient_addresses, CMC_string subject, CMC_string text_note, CMC_flags send_doc_flags, CMC_string file_paths, CMC_string file_names, CMC_string delimiter, CMC_ui_id ui_id)
CMC_return_code WINAPI cmc_logon(CMC_string service, CMC_string user, CMC_string password, CMC_object_identifier character_set, CMC_ui_id ui_id, CMC_uint16 caller_cmc_version, CMC_flags logon_flags, CMC_session_id *session, CMC_extension *logon_extensions)
CMC_message_reference * message_reference
Definition: xcmc.h:166
CMC_enum role
Definition: xcmc.h:145
CMC_object_identifier attach_type
Definition: xcmc.h:128
CMC_string name
Definition: xcmc.h:142
CMC_return_code WINAPI cmc_list(CMC_session_id session, CMC_string message_type, CMC_flags list_flags, CMC_message_reference *seed, CMC_uint32 *count, CMC_ui_id ui_id, CMC_message_summary **result, CMC_extension *list_extensions)
CMC_string attach_title
Definition: xcmc.h:127
CMC_uint32 byte_length
Definition: xcmc.h:188
CMC_sint8 unused1
Definition: xcmc.h:104
CMC_attachment * attachments
Definition: xcmc.h:172
CMC_sint16 unused2
Definition: xcmc.h:106
CMC_extension * recip_extensions
Definition: xcmc.h:147
short CMC_sint16
Definition: xcmc.h:27
CMC_return_code WINAPI cmc_free(CMC_buffer memory)
char CMC_sint8
Definition: xcmc.h:26
CMC_string subject
Definition: xcmc.h:168
CMC_uint32 CMC_ui_id
Definition: xcmc.h:40
CMC_string message_type
Definition: xcmc.h:167
void user(int argc, const char *argv[])
Definition: cmds.c:1350
CMC_uint32 length
Definition: xcmc.h:90
long int CMC_sint32
Definition: xcmc.h:28
CMC_counted_string CMC_message_reference
Definition: xcmc.h:94
CMC_return_code WINAPI cmc_logoff(CMC_session_id session, CMC_ui_id ui_id, CMC_flags logoff_flags, CMC_extension *logoff_extensions)
CMC_sint8 second
Definition: xcmc.h:97