Added in API level 30

SuggestionConnectionStatusListener


interface SuggestionConnectionStatusListener
android.net.wifi.WifiManager.SuggestionConnectionStatusListener

Interface for suggestion connection status listener. Should be implemented by applications and set when calling WifiManager.addSuggestionConnectionStatusListener( Executor, SuggestionConnectionStatusListener).

Summary

Public methods
abstract Unit
onConnectionStatus(wifiNetworkSuggestion: WifiNetworkSuggestion, failureReason: Int)

Called when the framework attempted to connect to a suggestion provided by the registering app, but the connection to the suggestion failed.

Public methods

onConnectionStatus

Added in API level 30
abstract fun onConnectionStatus(
    wifiNetworkSuggestion: WifiNetworkSuggestion,
    failureReason: Int
): Unit

Called when the framework attempted to connect to a suggestion provided by the registering app, but the connection to the suggestion failed.

Parameters
wifiNetworkSuggestion WifiNetworkSuggestion: The suggestion which failed to connect.
This value cannot be null.
failureReason Int: the connection failure reason code.
Value is one of the following: