3 * Copyright (c) 2012 Samsung Electronics Co., Ltd.
5 * Licensed under the Apache License, Version 2.0 (the License);
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
9 * http://www.apache.org/licenses/LICENSE-2.0
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
18 #ifndef SA_USERINTERACTION_H_
19 #define SA_USERINTERACTION_H_
25 #include "common/dm_error.h"
26 #include "serviceadapter/sa_define.h"
27 #include "ipc_common.h"
29 typedef struct _uic_option {
38 typedef struct _uic_res_data {
42 GList *res_multi_data;
45 typedef struct _uic_data {
46 uic_option *pUic_option;
49 uic_res_data *res_data;
53 * @par Description: API to free uic data
57 * @par Typical use case:
58 * @par Method of function operation:
59 * @par Important notes:
76 void free_uic_value(uic_data ** uic_value);
79 * @par Description: API to free uic res data
83 * @par Typical use case:
84 * @par Method of function operation:
85 * @par Important notes:
102 void free_res_data(uic_res_data * res_data);
104 * @par Description: API to execute user interaction option
108 * @par Typical use case:
109 * @par Method of function operation:
110 * @par Important notes:
112 * @param[in] uic_option
114 * @return DM_OK success
129 DM_ERROR exec_userinteration_option(char *data, uic_option ** uic_value);
132 * @par Description: API to display uic
136 * @par Typical use case:
137 * @par Method of function operation:
138 * @par Important notes:
139 * @param[in] uic_data
141 * @return DM_OK success
156 DM_ERROR ui_display(uic_data * uic_value);
159 * @par Description: API to confirm uic
163 * @par Typical use case:
164 * @par Method of function operation:
165 * @par Important notes:
166 * @param[in] uic_data
168 * @return DM_OK success
183 DM_ERROR ui_confirm_or_reject(uic_data * uic_value);
186 * @par Description: API to input uic
190 * @par Typical use case:
191 * @par Method of function operation:
192 * @par Important notes:
193 * @param[in] uic_data
195 * @return DM_OK success
210 DM_ERROR ui_text_input(uic_data * uic_value, char **result_data);
213 * @par Description: API to single choice uic
217 * @par Typical use case:
218 * @par Method of function operation:
219 * @par Important notes:
220 * @param[in] uic_data
221 * @param[in] response item
223 * @return DM_OK success
238 DM_ERROR ui_single_choice(uic_data * uic_value, GList ** responseItems);
241 * @par Description: API to multiple choice uic
245 * @par Typical use case:
246 * @par Method of function operation:
247 * @par Important notes:
248 * @param[in] uic_data
249 * @param[in] response item
251 * @return DM_OK success
266 DM_ERROR ui_multiple_choice(uic_data * uic_value, GList ** responseItems);
268 #endif /* SA_USERINTERACTION_H_ */