update tizen source
[framework/messaging/msg-service.git] / include / common / MsgCmdTypes.h
1 /*
2 *
3 * Copyright (c) 2000-2012 Samsung Electronics Co., Ltd. All Rights Reserved.
4 *
5 * This file is part of msg-service.
6 *
7 * Contact: Jaeyun Jeong <jyjeong@samsung.com>
8 *          Sangkoo Kim <sangkoo.kim@samsung.com>
9 *          Seunghwan Lee <sh.cat.lee@samsung.com>
10 *          SoonMin Jung <sm0415.jung@samsung.com>
11 *          Jae-Young Lee <jy4710.lee@samsung.com>
12 *          KeeBum Kim <keebum.kim@samsung.com>
13 *
14 * PROPRIETARY/CONFIDENTIAL
15 *
16 * This software is the confidential and proprietary information of
17 * SAMSUNG ELECTRONICS ("Confidential Information"). You shall not
18 * disclose such Confidential Information and shall use it only in
19 * accordance with the terms of the license agreement you entered
20 * into with SAMSUNG ELECTRONICS.
21 *
22 * SAMSUNG make no representations or warranties about the suitability
23 * of the software, either express or implied, including but not limited
24 * to the implied warranties of merchantability, fitness for a particular
25 * purpose, or non-infringement. SAMSUNG shall not be liable for any
26 * damages suffered by licensee as a result of using, modifying or
27 * distributing this software or its derivatives.
28 *
29 */
30
31 #ifndef MSG_CMD_TYPES_H
32 #define MSG_CMD_TYPES_H
33
34 /*==================================================================================================
35                                          INCLUDE FILES
36 ==================================================================================================*/
37 #include "MsgTypes.h"
38
39
40 /*==================================================================================================
41                                          DEFINES
42 ==================================================================================================*/
43 #define MAX_COOKIE_LEN 20
44
45
46 /*==================================================================================================
47                                          TYPES
48 ==================================================================================================*/
49 typedef unsigned int MSG_CMD_TYPE_T;
50
51 typedef unsigned int MSG_EVENT_TYPE_T;
52
53
54 /*==================================================================================================
55                                          STRUCTURES
56 ==================================================================================================*/
57 typedef struct _MSG_CMD_S
58 {
59         MSG_CMD_TYPE_T  cmdType;
60         char                            cmdCookie[MAX_COOKIE_LEN];
61         char                            cmdData[2];
62 } MSG_CMD_S;
63
64
65 typedef struct _MSG_EVENT_S
66 {
67         MSG_EVENT_TYPE_T        eventType;
68         MSG_ERROR_T                     result;
69         char                                    data[2];
70 } MSG_EVENT_S;
71
72
73 /*==================================================================================================
74                                          ENUMS
75 ==================================================================================================*/
76
77 enum _MSG_CMD_TYPE_E
78 {
79         MSG_CMD_OPEN_HANDLE = 0,
80         MSG_CMD_CLOSE_HANDLE,
81         MSG_CMD_GET_STORAGELIST,
82         MSG_CMD_ADD_MSG,
83         MSG_CMD_ADD_SYNCML_MSG,
84
85 // 05
86         MSG_CMD_UPDATE_MSG,
87         MSG_CMD_UPDATE_READ,
88         MSG_CMD_UPDATE_PROTECTED,
89         MSG_CMD_DELETE_MSG,
90         MSG_CMD_DELALL_MSGINFOLDER,
91
92 // 10
93         MSG_CMD_MOVE_MSGTOFOLDER,
94         MSG_CMD_MOVE_MSGTOSTORAGE,
95         MSG_CMD_COUNT_MSG,
96         MSG_CMD_GET_MSG,
97         MSG_CMD_GET_FOLDERVIEWLIST,
98
99 // 15
100         MSG_CMD_ADD_FOLDER,
101         MSG_CMD_UPDATE_FOLDER,
102         MSG_CMD_DELETE_FOLDER,
103         MSG_CMD_GET_FOLDERLIST,
104         MSG_CMD_SET_CONFIG,
105
106 // 20
107         MSG_CMD_GET_CONFIG,
108         MSG_CMD_GET_MSG_TYPE,
109         MSG_CMD_SUBMIT_REQ,
110         MSG_CMD_CANCEL_REQ,
111         MSG_CMD_REG_SENT_STATUS_CB,
112
113 // 25
114         MSG_CMD_REG_STORAGE_CHANGE_CB,
115         MSG_CMD_REG_INCOMING_MSG_CB,
116         MSG_CMD_REG_INCOMING_MMS_CONF_MSG_CB,
117         MSG_CMD_REG_INCOMING_SYNCML_MSG_CB,
118         MSG_CMD_REG_INCOMING_LBS_MSG_CB,
119
120 // 30
121         MSG_CMD_PLG_SENT_STATUS_CNF,
122         MSG_CMD_PLG_STORAGE_CHANGE_IND,
123         MSG_CMD_PLG_INCOMING_MSG_IND,
124         MSG_CMD_PLG_INCOMING_MMS_CONF,
125         MSG_CMD_PLG_INCOMING_SYNCML_IND,
126
127 // 35
128         MSG_CMD_PLG_INCOMING_LBS_IND,
129         MSG_CMD_PLG_INIT_SIM_BY_SAT,
130         MSG_CMD_GET_THREADVIEWLIST,
131         MSG_CMD_GET_CONVERSATIONVIEWLIST,
132         MSG_CMD_DELETE_THREADMESSAGELIST,
133
134 // 40
135         MSG_CMD_GET_CONTACT_COUNT,
136         MSG_CMD_GET_QUICKPANEL_DATA,
137         MSG_CMD_COUNT_BY_MSGTYPE,
138         MSG_CMD_RESET_DB,
139         MSG_CMD_GET_MEMSIZE,
140
141 // 45
142         MSG_CMD_BACKUP_MESSAGE,
143         MSG_CMD_RESTORE_MESSAGE,
144         MSG_CMD_UPDATE_THREAD_READ,
145         MSG_CMD_REG_SYNCML_MSG_OPERATION_CB,
146         MSG_CMD_SYNCML_OPERATION,
147
148 // 50
149         MSG_CMD_GET_REPORT_STATUS,
150
151 // end of MSG_CMD; new CMD should be defined before MSG_CMD_NUM
152         MSG_CMD_NUM
153 };
154
155
156 enum _MSG_EVENT_TYPE_E
157 {
158         MSG_EVENT_OPEN_HANDLE = 0,
159         MSG_EVENT_CLOSE_HANDLE,
160         MSG_EVENT_GET_STORAGELIST,
161         MSG_EVENT_ADD_MSG,
162         MSG_EVENT_ADD_SYNCML_MSG,
163
164 // 5
165         MSG_EVENT_UPDATE_MSG,
166         MSG_EVENT_UPDATE_READ,
167         MSG_EVENT_UPDATE_PROTECTED,
168         MSG_EVENT_DELETE_MSG,
169         MSG_EVENT_DELALL_MSGINFOLDER,
170
171 // 10
172         MSG_EVENT_MOVE_MSGTOFOLDER,
173         MSG_EVENT_MOVE_MSGTOSTORAGE,
174         MSG_EVENT_COUNT_MSG,
175         MSG_EVENT_GET_MSG,
176         MSG_EVENT_GET_FOLDERVIEWLIST,
177
178 // 15
179         MSG_EVENT_ADD_FOLDER,
180         MSG_EVENT_UPDATE_FOLDER,
181         MSG_EVENT_DELETE_FOLDER,
182         MSG_EVENT_GET_FOLDERLIST,
183         MSG_EVENT_SET_CONFIG,
184
185 // 20
186         MSG_EVENT_GET_CONFIG,
187         MSG_EVENT_GET_MSG_TYPE,
188         MSG_EVENT_SUBMIT_REQ,
189         MSG_EVENT_CANCEL_REQ,
190         MSG_EVENT_REG_SENT_STATUS_CB,
191
192 // 25
193         MSG_EVENT_REG_INCOMING_MSG_CB,
194         MSG_EVENT_REG_INCOMING_MMS_CONF_MSG_CB,
195         MSG_EVENT_REG_INCOMING_SYNCML_MSG_CB,
196         MSG_EVENT_REG_INCOMING_LBS_MSG_CB,
197         MSG_EVENT_REG_STORAGE_CHANGE_CB,
198
199 // 30
200         MSG_EVENT_PLG_SENT_STATUS_CNF,
201         MSG_EVENT_PLG_STORAGE_CHANGE_IND,
202         MSG_EVENT_PLG_INCOMING_MSG_IND,
203         MSG_EVENT_PLG_INCOMING_MMS_CONF,
204         MSG_EVENT_PLG_INCOMING_SYNCML_MSG_IND,
205
206 // 35
207         MSG_EVENT_PLG_INCOMING_LBS_MSG_IND,
208         MSG_EVENT_PLG_INIT_SIM_BY_SAT,
209         MSG_EVENT_GET_THREADVIEWLIST,
210         MSG_EVENT_GET_CONVERSATIONVIEWLIST,
211         MSG_EVENT_DELETE_THREADMESSAGELIST,
212
213 // 40
214         MSG_EVENT_GET_CONTACT_COUNT,
215         MSG_EVENT_GET_QUICKPANEL_DATA,
216         MSG_EVENT_COUNT_BY_MSGTYPE,
217         MSG_EVENT_RESET_DB,
218         MSG_EVENT_GET_MEMSIZE,
219
220 // 45
221         MSG_EVENT_BACKUP_MESSAGE, 
222         MSG_EVENT_RESTORE_MESSAGE, 
223         MSG_EVENT_UPDATE_THREAD_READ,
224         MSG_EVENT_REG_SYNCML_MSG_OPERATION_CB,
225         MSG_EVENT_SYNCML_OPERATION,
226
227 // 50
228         MSG_EVENT_GET_REPORT_STATUS,
229
230 // end of MSG_EVENT; new EVENT should be defined before MSG_EVENT_NUM
231         MSG_EVENT_NUM
232 };
233
234 #endif // MSG_CMD_TYPES_H
235