1 /*
2  * Copyright (C) 2022 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 
17 #include "structs.h"
18 
19 namespace android::hardware::radio::compat {
20 
21 namespace aidl = ::aidl::android::hardware::radio::sap;
22 
toHidl(const aidl::SapApduType sapApduType)23 V1_0::SapApduType toHidl(const aidl::SapApduType sapApduType) {
24     return V1_0::SapApduType(sapApduType);
25 }
26 
toHidl(const aidl::SapTransferProtocol sapTransferProtocol)27 V1_0::SapTransferProtocol toHidl(const aidl::SapTransferProtocol sapTransferProtocol) {
28     return V1_0::SapTransferProtocol(sapTransferProtocol);
29 }
30 
toAidl(const V1_0::SapResultCode sapResultCode)31 aidl::SapResultCode toAidl(const V1_0::SapResultCode sapResultCode) {
32     return aidl::SapResultCode(sapResultCode);
33 }
34 
toAidl(const V1_0::SapConnectRsp sapConnectRsp)35 aidl::SapConnectRsp toAidl(const V1_0::SapConnectRsp sapConnectRsp) {
36     return aidl::SapConnectRsp(sapConnectRsp);
37 }
38 
toAidl(const V1_0::SapDisconnectType sapDisconnectType)39 aidl::SapDisconnectType toAidl(const V1_0::SapDisconnectType sapDisconnectType) {
40     return aidl::SapDisconnectType(sapDisconnectType);
41 }
42 
toAidl(const V1_0::SapStatus sapStatus)43 aidl::SapStatus toAidl(const V1_0::SapStatus sapStatus) {
44     return aidl::SapStatus(sapStatus);
45 }
46 
47 }  // namespace android::hardware::radio::compat
48