1 /* 2 * Copyright (C) 2023 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16 #ifndef TELEPHONY_SATELLITE_CALL_CALLBACK_INTERFACE_H 17 #define TELEPHONY_SATELLITE_CALL_CALLBACK_INTERFACE_H 18 19 #include "call_manager_inner_type.h" 20 #include "tel_ril_call_parcel.h" 21 #include "iremote_broker.h" 22 #include "satellite_call_types.h" 23 #include "telephony_types.h" 24 25 namespace OHOS { 26 namespace Telephony { 27 class SatelliteCallCallbackInterface : public IRemoteBroker { 28 public: 29 virtual ~SatelliteCallCallbackInterface() = default; 30 31 /** 32 * @brief DialSatelliteResponse the result of dial by satellite. 33 * 34 * @param slotId Indicates the card slot index number, 35 * ranging from {@code 0} to the maximum card slot index number supported by the device. 36 * @param info Indicates dial action was success or failure. 37 * @return Returns {@code TELEPHONY_SUCCESS} on success, others on failure. 38 */ 39 virtual int32_t DialSatelliteResponse(int32_t slotId, const RadioResponseInfo &info) = 0; 40 41 /** 42 * @brief HangUpSatelliteResponse the result of hang up by satellite. 43 * 44 * @param slotId Indicates the card slot index number, 45 * ranging from {@code 0} to the maximum card slot index number supported by the device. 46 * @param info Indicates hang up action was success or failure. 47 * @return Returns {@code TELEPHONY_SUCCESS} on success, others on failure. 48 */ 49 virtual int32_t HangUpSatelliteResponse(int32_t slotId, const RadioResponseInfo &info) = 0; 50 51 /** 52 * @brief RejectSatelliteResponse the result of reject with reason by satellite. 53 * 54 * @param slotId Indicates the card slot index number, 55 * ranging from {@code 0} to the maximum card slot index number supported by the device. 56 * @param info Indicates reject action was success or failure. 57 * @return Returns {@code TELEPHONY_SUCCESS} on success, others on failure. 58 */ 59 virtual int32_t RejectSatelliteResponse(int32_t slotId, const RadioResponseInfo &info) = 0; 60 61 /** 62 * @brief AnswerSatelliteResponse the result of answer by satellite. 63 * 64 * @param slotId Indicates the card slot index number, 65 * ranging from {@code 0} to the maximum card slot index number supported by the device. 66 * @param info Indicates answer action was success or failure. 67 * @return Returns {@code TELEPHONY_SUCCESS} on success, others on failure. 68 */ 69 virtual int32_t AnswerSatelliteResponse(int32_t slotId, const RadioResponseInfo &info) = 0; 70 71 /** 72 * @brief CallStateChangeReport receive call state changed notification with slotId by satellite. 73 * 74 * @param slotId Indicates the card slot index number, 75 * ranging from {@code 0} to the maximum card slot index number supported by the device. 76 * @return Returns {@code TELEPHONY_SUCCESS} on success, others on failure. 77 */ 78 virtual int32_t CallStateChangeReport(int32_t slotId) = 0; 79 80 /** 81 * @brief GetSatelliteCallsDataResponse the result of get satellite calls data by satellite. 82 * 83 * @param slotId Indicates the card slot index number, 84 * ranging from {@code 0} to the maximum card slot index number supported by the device. 85 * @param info Indicates get action was success or failure. 86 * @return Returns {@code TELEPHONY_SUCCESS} on success, others on failure. 87 */ 88 virtual int32_t GetSatelliteCallsDataResponse(int32_t slotId, const RadioResponseInfo &info) = 0; 89 90 /** 91 * @brief GetSatelliteCallsDataResponse the result of get ims calls data by satellite. 92 * 93 * @param slotId Indicates the card slot index number, 94 * ranging from {@code 0} to the maximum card slot index number supported by the device. 95 * @param callList Indicates the result of get ims current call list. 96 * @return Returns {@code TELEPHONY_SUCCESS} on success, others on failure. 97 */ 98 virtual int32_t GetSatelliteCallsDataResponse(int32_t slotId, const SatelliteCurrentCallList &callList) = 0; 99 100 public: 101 DECLARE_INTERFACE_DESCRIPTOR(u"OHOS.Telephony.SatelliteCallCallback"); 102 }; 103 } // namespace Telephony 104 } // namespace OHOS 105 106 #endif // TELEPHONY_SATELLITE_CALL_CALLBACK_INTERFACE_H 107