2 * Copyright (C) 2017 The Android Open Source Project
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 package android.hardware.usb@1.1;
19 import android.hardware.usb@1.0;
22 * Callback object used for all the IUsb async methods which expects a result.
23 * Caller is expected to register the callback object using setCallback method
24 * to receive updates on the PortStatus.
26 interface IUsbCallback extends @1.0::IUsbCallback {
28 * Used to convey the current port status to the caller.
29 * Must be called either when PortState changes due to the port partner or
30 * when caller requested for the PortStatus update through queryPortStatus.
32 * @param currentPortStatus vector object of current status(PortStatus_1_1
33 * of all the typeC ports in the device.
34 * @param retval SUCCESS when the required information was enquired form
35 * kernel and the PortStatus_1_1 object was built.
38 oneway notifyPortStatusChange_1_1(vec<PortStatus_1_1> currentPortStatus,