blob: 544d02ba76ff47914cdca32cfc60755285f5489d [file] [log] [blame]
Lorenzo Colitti2edad7a2014-05-21 16:23:43 -07001/*
2 * Copyright (C) 2014 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
17package android.net;
18
19import android.net.IpConfiguration;
Jaewan Kim32b3f2c2014-10-20 12:04:13 +090020import android.net.IEthernetServiceListener;
Quentin Perret369c79b2022-03-17 15:20:53 +000021import android.net.IEthernetNetworkManagementListener;
James Mattis1ecadfa2022-01-28 13:42:38 -080022import android.net.EthernetNetworkUpdateRequest;
Lorenzo Colitti19b8b882020-01-24 19:29:17 +090023import android.net.ITetheredInterfaceCallback;
Lorenzo Colitti2edad7a2014-05-21 16:23:43 -070024
25/**
26 * Interface that answers queries about, and allows changing
27 * ethernet configuration.
28 */
29/** {@hide} */
30interface IEthernetManager
31{
Pavel Maltsev50ec1f32017-10-31 15:34:16 -070032 String[] getAvailableInterfaces();
33 IpConfiguration getConfiguration(String iface);
34 void setConfiguration(String iface, in IpConfiguration config);
35 boolean isAvailable(String iface);
Jaewan Kim32b3f2c2014-10-20 12:04:13 +090036 void addListener(in IEthernetServiceListener listener);
37 void removeListener(in IEthernetServiceListener listener);
Lorenzo Colitti013187d2020-03-17 00:16:13 +090038 void setIncludeTestInterfaces(boolean include);
Lorenzo Colitti19b8b882020-01-24 19:29:17 +090039 void requestTetheredInterface(in ITetheredInterfaceCallback callback);
40 void releaseTetheredInterface(in ITetheredInterfaceCallback callback);
James Mattis1ecadfa2022-01-28 13:42:38 -080041 void updateConfiguration(String iface, in EthernetNetworkUpdateRequest request,
Quentin Perret369c79b2022-03-17 15:20:53 +000042 in IEthernetNetworkManagementListener listener);
43 void connectNetwork(String iface, in IEthernetNetworkManagementListener listener);
44 void disconnectNetwork(String iface, in IEthernetNetworkManagementListener listener);
Lorenzo Colitti2edad7a2014-05-21 16:23:43 -070045}