public class SupplicantWifiScannerImpl extends WifiScannerImpl implements Handler.Callback
for more details on each method.
Modifier and Type | Class and Description |
---|---|
static class |
SupplicantWifiScannerImpl.HwPnoDebouncer
HW PNO Debouncer is used to debounce PNO requests.
|
WifiScannerImpl.WifiScannerImplFactory
Modifier and Type | Field and Description |
---|---|
static String |
BACKGROUND_PERIOD_ALARM_TAG |
static int |
MAX_HIDDEN_NETWORK_IDS_PER_SCAN |
static String |
TIMEOUT_ALARM_TAG |
DEFAULT_FACTORY, SCAN_RESULT_SORT_COMPARATOR
Constructor and Description |
---|
SupplicantWifiScannerImpl(Context context,
WifiNative wifiNative,
ChannelHelper channelHelper,
Looper looper,
Clock clock) |
SupplicantWifiScannerImpl(Context context,
WifiNative wifiNative,
Looper looper,
Clock clock) |
Modifier and Type | Method and Description |
---|---|
void |
cleanup()
Cleanup any ongoing operations.
|
ChannelHelper |
getChannelHelper()
Get a ChannelHelper that can be used to perform operations on scan channels
|
WifiScanner.ScanData[] |
getLatestBatchedScanResults(boolean flush)
Get the latest cached scan results from the last scan event.
|
WifiScanner.ScanData |
getLatestSingleScanResults()
Get the scan results of the most recent single scan.
|
boolean |
getScanCapabilities(WifiNative.ScanCapabilities capabilities)
Get the supported scan capabilities.
|
boolean |
handleMessage(Message msg) |
boolean |
isHwPnoSupported(boolean isConnectedPno)
This returns whether HW PNO is supported or not.
|
void |
pauseBatchedScan()
Pause the currently active background scan
|
void |
resetHotlist()
Reset any active hotlist
|
boolean |
resetHwPnoList()
Reset PNO list to terminate PNO background scan.
|
void |
restartBatchedScan()
Restart the currently paused background scan
|
boolean |
setHotlist(WifiScanner.HotlistSettings settings,
WifiNative.HotlistEventHandler eventHandler)
Set a new hotlist
|
boolean |
setHwPnoList(WifiNative.PnoSettings settings,
WifiNative.PnoEventHandler eventHandler)
Set PNO list to start PNO background scan.
|
boolean |
shouldScheduleBackgroundScanForHwPno()
This returns whether a background scan should be running for HW PNO scan or not.
|
boolean |
startBatchedScan(WifiNative.ScanSettings settings,
WifiNative.ScanEventHandler eventHandler)
Start a background scan.
|
boolean |
startSingleScan(WifiNative.ScanSettings settings,
WifiNative.ScanEventHandler eventHandler)
Start a one time scan.
|
void |
stopBatchedScan()
Stop the currently active background scan
|
boolean |
trackSignificantWifiChange(WifiScanner.WifiChangeSettings settings,
WifiNative.SignificantWifiChangeEventHandler handler)
Start tracking significant wifi changes
|
void |
untrackSignificantWifiChange()
Stop tracking significant wifi changes
|
public static final String BACKGROUND_PERIOD_ALARM_TAG
public static final String TIMEOUT_ALARM_TAG
public static final int MAX_HIDDEN_NETWORK_IDS_PER_SCAN
public SupplicantWifiScannerImpl(Context context, WifiNative wifiNative, ChannelHelper channelHelper, Looper looper, Clock clock)
public SupplicantWifiScannerImpl(Context context, WifiNative wifiNative, Looper looper, Clock clock)
public void cleanup()
WifiScannerImpl
cleanup
in class WifiScannerImpl
public boolean getScanCapabilities(WifiNative.ScanCapabilities capabilities)
WifiScannerImpl
getScanCapabilities
in class WifiScannerImpl
capabilities
- Object that will be filled with the supported capabilities if successfulpublic ChannelHelper getChannelHelper()
WifiScannerImpl
getChannelHelper
in class WifiScannerImpl
public boolean startSingleScan(WifiNative.ScanSettings settings, WifiNative.ScanEventHandler eventHandler)
WifiScannerImpl
startSingleScan
in class WifiScannerImpl
public WifiScanner.ScanData getLatestSingleScanResults()
WifiScannerImpl
getLatestSingleScanResults
in class WifiScannerImpl
public boolean startBatchedScan(WifiNative.ScanSettings settings, WifiNative.ScanEventHandler eventHandler)
WifiScannerImpl
startBatchedScan
in class WifiScannerImpl
public void stopBatchedScan()
WifiScannerImpl
stopBatchedScan
in class WifiScannerImpl
public void pauseBatchedScan()
WifiScannerImpl
pauseBatchedScan
in class WifiScannerImpl
public void restartBatchedScan()
WifiScannerImpl
restartBatchedScan
in class WifiScannerImpl
public boolean handleMessage(Message msg)
handleMessage
in interface Handler.Callback
public WifiScanner.ScanData[] getLatestBatchedScanResults(boolean flush)
WifiScannerImpl
getLatestBatchedScanResults
in class WifiScannerImpl
public boolean setHwPnoList(WifiNative.PnoSettings settings, WifiNative.PnoEventHandler eventHandler)
WifiScannerImpl
setHwPnoList
in class WifiScannerImpl
settings
- PNO settings for this scan.eventHandler
- Event handler for notifying the scan results.public boolean resetHwPnoList()
WifiScannerImpl
resetHwPnoList
in class WifiScannerImpl
public boolean isHwPnoSupported(boolean isConnectedPno)
WifiScannerImpl
isHwPnoSupported
in class WifiScannerImpl
isConnectedPno
- Whether this is connected PNO vs disconnected PNO.public boolean shouldScheduleBackgroundScanForHwPno()
WifiScannerImpl
shouldScheduleBackgroundScanForHwPno
in class WifiScannerImpl
public boolean setHotlist(WifiScanner.HotlistSettings settings, WifiNative.HotlistEventHandler eventHandler)
WifiScannerImpl
setHotlist
in class WifiScannerImpl
public void resetHotlist()
WifiScannerImpl
resetHotlist
in class WifiScannerImpl
public boolean trackSignificantWifiChange(WifiScanner.WifiChangeSettings settings, WifiNative.SignificantWifiChangeEventHandler handler)
WifiScannerImpl
trackSignificantWifiChange
in class WifiScannerImpl
public void untrackSignificantWifiChange()
WifiScannerImpl
untrackSignificantWifiChange
in class WifiScannerImpl