4 * Copyright (c) 2014 Samsung Electronics Co., Ltd. All rights reserved.
6 * Contact: Ja-young Gu <jygu@samsung.com>
8 * Licensed under the Apache License, Version 2.0 (the "License");
9 * you may not use this file except in compliance with the License.
10 * You may obtain a copy of the License at
12 * http://www.apache.org/licenses/LICENSE-2.0
14 * Unless required by applicable law or agreed to in writing, software
15 * distributed under the License is distributed on an "AS IS" BASIS,
16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 * See the License for the specific language governing permissions and
18 * limitations under the License.
27 * @addtogroup CAPI_TELEPHONY_SERVICE_SAT
34 #include <tapi_common.h>
43 * @brief Sends the user choice of the main menu options to the USIM.
45 * @details <b> Notes: </b>
46 * A set of possible menu options are supplied by the USIM
47 * using the proactive command SET UP MENU. The telephony server receives the command
48 * and publishes this information. The SAT UI application should list the menu when it is initially launched.
49 * If the user subsequently chooses an option, then the SAT UI application replies to
50 * the command with the user's choice using this API. \n
52 * This API makes a Dbus method call to the Telephony Server and gets an immediate feedback.
53 * However it just means that the API request has been transfered to the CP successfully.
54 * The actual operation result is delivered with the async response as below. \n
56 * <b> Sync (or) Async: </b> This is an Asynchronous API. \n
58 * <b> Prospective Clients: </b> SAT-UI.
62 * @privilege %http://tizen.org/privilege/telephony.admin
64 * @remarks You must not use this function. This function is dedicated to the SAT UI embedded application only.
66 * @param[in] handle The handle from tel_init()
68 * @param[in] pMenuSelect #TelSatMenuSelectionReqInfo_t contains information like which SAT menu item has been selected or whether help is required
70 * @param[in] callback To register a callback function for result
72 * @param[in] user_data The user data for user specification
74 * @return The return type (int)\n
75 * #TAPI_API_SUCCESS - indicates that the operation has completed successfully,\n
76 * else it will return failure and an error code (Refer #TapiResult_t).
78 * @pre This function is supposed to be called after getting the #TAPI_EVENT_SAT_SETUP_MENU_IND event from the telephony server.
80 * @see tel_get_sat_main_menu_info()
82 int tel_select_sat_menu(TapiHandle *handle, const TelSatMenuSelectionReqInfo_t* pMenuSelect, tapi_response_cb callback, void *user_data);
85 * @brief Downloads SAT events to the USIM.
87 * @details <b> Notes: </b>
88 * A set of events for the terminal to monitor can be supplied by the USIM using the proactive command SET UP EVENT
89 * LIST. If the USIM has sent this command, and an event which is part of the list subsequently occurs, the terminal
90 * informs the USIM using this function, relevant for that event.
91 * If the USIM commands to monitor a browser termination event, the SAT-UI application has to call this function. \n
93 * This API makes a Dbus method call to the Telephony Server and gets an immediate feedback.
94 * However it just means that the API request has been transfered to the CP successfully.
95 * The actual operation result is delivered with the async response as below. \n
97 * <b> Sync (or) Async: </b> This is an Asynchronous API. \n
99 * <b> Prospective Clients: </b> SAT-UI \n
102 * @privlevel platform
103 * @privilege %http://tizen.org/privilege/telephony.admin
105 * @remarks You must not use this function. This function is dedicated to the SAT UI embedded application only.
107 * @param[in] handle The handle from tel_init()
109 * @param[in] pEventData #TelSatEventDownloadReqInfo_t contains the necessary parameters like event types and information associated with it
111 * @param[in] callback To register a callback function for result
113 * @param[in] user_data The user data for user specification
115 * @return The return type (int) \n
116 * #TAPI_API_SUCCESS - indicates that the operation is completed successfully, \n
117 * else it will return failure and an error code (Refer #TapiResult_t).
119 * @pre A SET UP EVENT LIST proactive command supplies a set of events to monitor.
121 int tel_download_sat_event(TapiHandle *handle, const TelSatEventDownloadReqInfo_t* pEventData, tapi_response_cb callback, void *user_data);
124 * @brief Sends the UI display status of the alpha identifier of a specific proactive command to the Telephony Server.
126 * @details When SAT-UI receives a proactive command, SAT-UI should draw a UI for the relevant command.
127 * As it completes, SAT-UI informs the USIM by calling this function. Afterwards, the USIM is getting ready to send another command. \n
129 * This function makes a Dbus method call to the Telephony Server and gets an immediate feedback. \n
131 * <b> Sync (or) Async: </b> This is a Synchronous API. \n
133 * <b> Prospective Clients: </b> SAT-UI \n
136 * @privlevel platform
137 * @privilege %http://tizen.org/privilege/telephony.admin
139 * @remarks You must not use this function. This function is dedicated to the SAT UI embedded application only.
141 * @param[in] handle The handle from tel_init()
143 * @param[in] commandId The proactive command ID from the application
145 * @param[in] status #TelSatUiDisplayStatusType_t contains the display status(SUCCESS/FAIL)
147 * @return The return type (int)\n
148 * #TAPI_API_SUCCESS - indicates that the operation has completed successfully,\n
149 * else it will return failure and an error code (Refer #TapiResult_t).
151 * @pre The display request for the alpha identifier of a Proactive Command should be sent by the Telephony Server.
153 * @post If the display status is SUCCESS, the Telephony Server sends a request to the application for Proactive Command Execution.
154 * If the display status is FAIL, the Telephony Server sends a Terminal Response for the Proactive Command.
156 int tel_send_sat_ui_display_status(TapiHandle *handle, int commandId, TelSatUiDisplayStatusType_t status);
159 * @brief Sends UI User confirmation data for a specific Proactive Command to the Telephony Server.
161 * @details In case the proactive commands need user response, SAT-UI can send it using this function.
162 * The response can be 'OK', 'Cancel', 'Move Back', and 'End Session'. Upon this response, the USIM can send
163 * a proactive command subsequently to indicate the next UI action. \n
165 * This function makes a Dbus method call to the Telephony Server and gets an immediate feedback. \n
167 * <b> Sync (or) Async: </b> This is a synchronous API. \n
169 * <b> Prospective Clients: </b> SAT-UI. \n
172 * @privlevel platform
173 * @privilege %http://tizen.org/privilege/telephony.admin
175 * @remarks You must not use this function. This function is dedicated to the SAT UI embedded application only.
177 * @param[in] handle The handle from tel_init()
179 * @param[in] pUserConfirmData #TelSatUiUserConfirmInfo_t contains specific user confirmation data
181 * @return The return type (int)\n
182 * #TAPI_API_SUCCESS - indicates that the operation has completed successfully,\n
183 * else it will return failure and an error code (Refer #TapiResult_t).
185 * @pre The User Confirmation request for a specific Proactive Command should be sent to the application by the Telephony Server.
187 * @post If the User Confirmation is positive, the Telephony Server sends a request to the application for Proactive Command Execution.
188 * If the User Confirmation is negative, the Telephony Server sends a Terminal Response for the Proactive Command.
190 int tel_send_sat_ui_user_confirm(TapiHandle *handle, TelSatUiUserConfirmInfo_t *pUserConfirmData);
193 * @brief Provides SAT(Sim Application toolkit) Main Menu information for SAT-UI.
195 * @details Once the USIM supplies the SET UP MENU proactive command, the telephony server not only publishes the
196 * #TAPI_EVENT_SAT_SETUP_MENU_IND event but also caches the menu information.
197 * The SAT-UI application can get the menu list using this function. \n
199 * This function makes a Dbus method call to the Telephony Server and gets an immediate feedback. \n
201 * <b> Sync (or) Async: </b> This is a Synchronous API. \n
203 * <b> Prospective Clients: </b> SAT-UI.
207 * @privilege %http://tizen.org/privilege/telephony
209 * @remarks You must not use this function. This function is dedicated to the SAT UI embedded application only.
211 * @param[in] handle The handle from tel_init()
213 * @param[out] pMainMenu #TelSatSetupMenuInfo_t contains all menu related information which is required such as a menu title, an icon, an item count, and so on
215 * @return The return type (int)\n
216 * #TAPI_API_SUCCESS - indicates that the operation has completed successfully,\n
217 * else it will return failure and an error code (Refer #TapiResult_t).
219 * @pre When SAT SIM is inserted we can get meaningful data. Without SAT SIM, null is returned.
221 * @see tel_select_sat_menu()
223 int tel_get_sat_main_menu_info(TapiHandle *handle, TelSatSetupMenuInfo_t *pMainMenu);
226 * @brief Provides the Operation result(s) for Proactive Command execution by the Application(s) to the Telephony Server.
228 * @details The USIM commands the terminal to do some predefined action, such as sending a short message,
229 * making a voice call, launching an Internet browser, and so on. Those actions are defined by 3GPP TS31.111.
230 * Once an application executes the requested action by USIM, it reports the operation result to the USIM using this function. \n
232 * This function makes a Dbus method call to the Telephony Server and gets an immediate feedback. \n
234 * <b> Sync (or) Async: </b> This is a Synchronous API. \n
236 * <b> Prospective Clients: </b> Embeded applications which are predefined by 3GPP TS31.111.
239 * @privlevel platform
240 * @privilege %http://tizen.org/privilege/telephony.admin
242 * @remarks You must not use this function. This function is dedicated to the SAT UI embedded application only.
244 * @param[in] handle The handle from tel_init()
246 * @param[out] pAppRetInfo #TelSatAppsRetInfo_t contains an execution result of a specific proactive command by the application
248 * @return The return type (int)\n
249 * #TAPI_API_SUCCESS - indicates that the operation has completed successfully,\n
250 * else it will return failure and an error code (Refer #TapiResult_t).
252 * @pre The Proactive Command execution request should be sent by the Telephony Server to SAT related applications.
254 int tel_send_sat_app_exec_result(TapiHandle *handle, TelSatAppsRetInfo_t *pAppRetInfo);
260 #endif /* _ITAPI_SAT_H_ */