OSDN Git Service

faae90bec86f78063dc1aec1f23a70aaf91d421a
[android-x86/frameworks-base.git] / wifi / java / android / net / wifi / IWifiManager.aidl
1 /**
2  * Copyright (c) 2008, 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 package android.net.wifi;
18
19
20 import android.content.pm.ParceledListSlice;
21
22 import android.net.wifi.hotspot2.PasspointConfiguration;
23
24 import android.net.wifi.WifiConfiguration;
25 import android.net.wifi.WifiInfo;
26 import android.net.wifi.ScanSettings;
27 import android.net.wifi.ScanResult;
28 import android.net.wifi.PasspointManagementObjectDefinition;
29 import android.net.wifi.WifiConnectionStatistics;
30 import android.net.wifi.WifiActivityEnergyInfo;
31 import android.net.Network;
32
33 import android.net.DhcpInfo;
34
35 import android.os.Messenger;
36 import android.os.ResultReceiver;
37 import android.os.WorkSource;
38
39 /**
40  * Interface that allows controlling and querying Wi-Fi connectivity.
41  *
42  * {@hide}
43  */
44 interface IWifiManager
45 {
46     int getSupportedFeatures();
47
48     WifiActivityEnergyInfo reportActivityInfo();
49
50     /**
51      * Requests the controller activity info asynchronously.
52      * The implementor is expected to reply with the
53      * {@link android.net.wifi.WifiActivityEnergyInfo} object placed into the Bundle with the key
54      * {@link android.os.BatteryStats#RESULT_RECEIVER_CONTROLLER_KEY}. The result code is ignored.
55      */
56     oneway void requestActivityInfo(in ResultReceiver result);
57
58     ParceledListSlice getConfiguredNetworks();
59
60     ParceledListSlice getPrivilegedConfiguredNetworks();
61
62     WifiConfiguration getMatchingWifiConfig(in ScanResult scanResult);
63
64     int addOrUpdateNetwork(in WifiConfiguration config);
65
66     boolean addOrUpdatePasspointConfiguration(in PasspointConfiguration config);
67
68     boolean removePasspointConfiguration(in String fqdn);
69
70     List<PasspointConfiguration> getPasspointConfigurations();
71
72     void queryPasspointIcon(long bssid, String fileName);
73
74     int matchProviderWithCurrentNetwork(String fqdn);
75
76     void deauthenticateNetwork(long holdoff, boolean ess);
77
78     boolean removeNetwork(int netId);
79
80     boolean enableNetwork(int netId, boolean disableOthers);
81
82     boolean disableNetwork(int netId);
83
84     void startScan(in ScanSettings requested, in WorkSource ws, in String packageName);
85
86     List<ScanResult> getScanResults(String callingPackage);
87
88     void disconnect();
89
90     void reconnect();
91
92     void reassociate();
93
94     WifiInfo getConnectionInfo();
95
96     boolean setWifiEnabled(String packageName, boolean enable);
97
98     int getWifiEnabledState();
99
100     void setCountryCode(String country, boolean persist);
101
102     String getCountryCode();
103
104     boolean isDualBandSupported();
105
106     boolean saveConfiguration();
107
108     DhcpInfo getDhcpInfo();
109
110     boolean isScanAlwaysAvailable();
111
112     boolean acquireWifiLock(IBinder lock, int lockType, String tag, in WorkSource ws);
113
114     void updateWifiLockWorkSource(IBinder lock, in WorkSource ws);
115
116     boolean releaseWifiLock(IBinder lock);
117
118     void initializeMulticastFiltering();
119
120     boolean isMulticastEnabled();
121
122     void acquireMulticastLock(IBinder binder, String tag);
123
124     void releaseMulticastLock();
125
126     void setWifiApEnabled(in WifiConfiguration wifiConfig, boolean enable);
127
128     void updateInterfaceIpState(String ifaceName, int mode);
129
130     boolean startSoftAp(in WifiConfiguration wifiConfig);
131
132     boolean stopSoftAp();
133
134     WifiConfiguration startLocalOnlyHotspot(in Messenger messenger, in IBinder binder);
135
136     void stopLocalOnlyHotspot();
137
138     void startWatchLocalOnlyHotspot(in Messenger messenger, in IBinder binder);
139
140     void stopWatchLocalOnlyHotspot();
141
142     int getWifiApEnabledState();
143
144     WifiConfiguration getWifiApConfiguration();
145
146     void setWifiApConfiguration(in WifiConfiguration wifiConfig);
147
148     Messenger getWifiServiceMessenger();
149
150     void enableTdls(String remoteIPAddress, boolean enable);
151
152     void enableTdlsWithMacAddress(String remoteMacAddress, boolean enable);
153
154     String getCurrentNetworkWpsNfcConfigurationToken();
155
156     void enableVerboseLogging(int verbose);
157
158     int getVerboseLoggingLevel();
159
160     void enableAggressiveHandover(int enabled);
161     int getAggressiveHandover();
162
163     void setAllowScansWithTraffic(int enabled);
164     int getAllowScansWithTraffic();
165
166     boolean setEnableAutoJoinWhenAssociated(boolean enabled);
167     boolean getEnableAutoJoinWhenAssociated();
168
169     void enableWifiConnectivityManager(boolean enabled);
170
171     WifiConnectionStatistics getConnectionStatistics();
172
173     void disableEphemeralNetwork(String SSID);
174
175     void factoryReset();
176
177     Network getCurrentNetwork();
178
179     byte[] retrieveBackupData();
180
181     void restoreBackupData(in byte[] data);
182
183     void restoreSupplicantBackupData(in byte[] supplicantData, in byte[] ipConfigData);
184 }
185