1 /* 2 * Copyright (C) 2021 The Android Open Source Project 3 * 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 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 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. 15 */ 16 #pragma once 17 18 #include "GuaranteedCallback.h" 19 20 #include <aidl/android/hardware/radio/config/IRadioConfigResponse.h> 21 #include <android/hardware/radio/config/1.3/IRadioConfigResponse.h> 22 23 namespace android::hardware::radio::compat { 24 25 class RadioConfigResponse : public config::V1_3::IRadioConfigResponse { 26 GuaranteedCallback<aidl::android::hardware::radio::config::IRadioConfigResponse, 27 aidl::android::hardware::radio::config::IRadioConfigResponseDefault> 28 mCallback; 29 30 Return<void> getSimSlotsStatusResponse( 31 const V1_0::RadioResponseInfo& info, 32 const hidl_vec<config::V1_0::SimSlotStatus>& slotStatus) override; 33 Return<void> setSimSlotsMappingResponse(const V1_0::RadioResponseInfo& info) override; 34 Return<void> getPhoneCapabilityResponse( 35 const V1_0::RadioResponseInfo& info, 36 const config::V1_1::PhoneCapability& phoneCapability) override; 37 Return<void> setPreferredDataModemResponse(const V1_0::RadioResponseInfo& info) override; 38 Return<void> setModemsConfigResponse(const V1_0::RadioResponseInfo& info) override; 39 Return<void> getModemsConfigResponse(const V1_0::RadioResponseInfo& info, 40 const config::V1_1::ModemsConfig& modemsConfig) override; 41 Return<void> getSimSlotsStatusResponse_1_2( 42 const V1_0::RadioResponseInfo& info, 43 const hidl_vec<config::V1_2::SimSlotStatus>& slotStatus) override; 44 Return<void> getHalDeviceCapabilitiesResponse(const V1_6::RadioResponseInfo& info, 45 bool modemReducedFeatureSet1) override; 46 47 public: 48 void setResponseFunction( 49 std::shared_ptr<aidl::android::hardware::radio::config::IRadioConfigResponse> callback); 50 51 std::shared_ptr<aidl::android::hardware::radio::config::IRadioConfigResponse> respond(); 52 }; 53 54 } // namespace android::hardware::radio::compat 55