• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2018 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 import android.net.wifi.SoftApCapability;
19 import android.net.wifi.SoftApInfo;
20 
21 import android.net.wifi.WifiClient;
22 
23 /**
24  * Interface for Soft AP callback.
25  *
26  * @hide
27  */
28 oneway interface ISoftApCallback
29 {
30     /**
31      * Service to manager callback providing current soft AP state. The possible
32      * parameter values listed are defined in WifiManager.java
33      *
34      * @param state new AP state. One of WIFI_AP_STATE_DISABLED,
35      *        WIFI_AP_STATE_DISABLING, WIFI_AP_STATE_ENABLED,
36      *        WIFI_AP_STATE_ENABLING, WIFI_AP_STATE_FAILED
37      * @param failureReason reason when in failed state. One of
38      *        SAP_START_FAILURE_GENERAL, SAP_START_FAILURE_NO_CHANNEL
39      */
onStateChanged(int state, int failureReason)40     void onStateChanged(int state, int failureReason);
41 
42     /**
43      * Service to manager callback providing connected client's information.
44      *
45      * @param clients the currently connected clients
46      */
onConnectedClientsChanged(in List<WifiClient> clients)47     void onConnectedClientsChanged(in List<WifiClient> clients);
48 
49     /**
50      * Service to manager callback providing information of softap.
51      *
52      * @param softApInfo is the softap information. {@link SoftApInfo}
53      */
onInfoChanged(in SoftApInfo softApInfo)54     void onInfoChanged(in SoftApInfo softApInfo);
55 
56 
57     /**
58      * Service to manager callback providing capability of softap.
59      *
60      * @param capability is the softap capability. {@link SoftApCapability}
61      */
onCapabilityChanged(in SoftApCapability capability)62     void onCapabilityChanged(in SoftApCapability capability);
63 
64     /**
65      * Service to manager callback providing blocked client of softap with specific reason code.
66      *
67      * @param client the currently blocked client.
68      * @param blockedReason one of blocked reason from {@link WifiManager.SapClientBlockedReason}
69      */
onBlockedClientConnecting(in WifiClient client, int blockedReason)70     void onBlockedClientConnecting(in WifiClient client, int blockedReason);
71 }
72