2 * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
4 * Licensed under the Apache License, Version 2.0 (the License);
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an AS IS BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
17 #ifndef __CAPI_TELEPHONY_CALL_H__
18 #define __CAPI_TELEPHONY_CALL_H__
21 * @file telephony_call.h
22 * @brief This file contains call APIs and related enumeration.
25 #include "telephony_common.h"
32 * @addtogroup CAPI_TELEPHONY_INFORMATION_CALL
37 * @brief Enumeration for the call state.
42 TELEPHONY_CALL_STATE_IDLE, /**< There exists no calls. */
43 TELEPHONY_CALL_STATE_CONNECTING, /**< There exists at least one call that is dialing, alerting or incoming */
44 TELEPHONY_CALL_STATE_CONNECTED, /**< There exist active or held calls, and no calls are dialing, alerting or incoming*/
45 } telephony_call_state_e;
48 * @brief Gets the voice call state of the telephony service.
49 * @details Determines if the voice call is connecting, connected, or idle.
53 * @privilege %http://tizen.org/privilege/telephony
55 * @remarks When you are dialing a number or a new voice call is ringing,
56 * the state of the voice call is #TELEPHONY_CALL_STATE_CONNECTING.
57 * When a new voice call is connecting while another voice call is already connected,
58 * the state of the voice call is #TELEPHONY_CALL_STATE_CONNECTING as well.
60 * @param[in] handle The handle from telephony_init()
61 * @param[out] call_state The current state of the voice call
63 * @return @c 0 on success,
64 * otherwise a negative error value
66 * @retval #TELEPHONY_ERROR_NONE Successful
67 * @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter
68 * @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied
69 * @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported
70 * @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed
72 int telephony_call_get_voice_call_state(telephony_h handle, telephony_call_state_e *call_state);
75 * @brief Gets the video call state of the telephony service.
76 * @details Determines if the video call is connecting, connected, or idle.
80 * @privilege %http://tizen.org/privilege/telephony
82 * @remarks When you are dialing a number or a new video call is ringing,
83 * the state of the video call is #TELEPHONY_CALL_STATE_CONNECTING.
84 * If a video call is connected, then the state of any other call cannot be
85 * #TELEPHONY_CALL_STATE_CONNECTING and #TELEPHONY_CALL_STATE_CONNECTED.
87 * @param[in] handle The handle from telephony_init()
88 * @param[out] call_state The current state of the video call
90 * @return @c 0 on success,
91 * otherwise a negative error value
93 * @retval #TELEPHONY_ERROR_NONE Successful
94 * @retval #TELEPHONY_ERROR_INVALID_PARAMETER Invalid parameter
95 * @retval #TELEPHONY_ERROR_PERMISSION_DENIED Permission denied
96 * @retval #TELEPHONY_ERROR_NOT_SUPPORTED Not supported
97 * @retval #TELEPHONY_ERROR_OPERATION_FAILED Operation failed
99 int telephony_call_get_video_call_state(telephony_h handle, telephony_call_state_e *call_state);
109 #endif // __CAPI_TELEPHONY_CALL_H__