public static interface Connection.OnConnectionListener
| Modifier and Type | Method and Description |
|---|---|
void |
onConnectionEstablished(android.content.Context context,
Connection.ConnectionType type,
android.net.NetworkInfo info)
Invoked whenever registered
ConnectionStateReceiver revives an Intent for the
ConnectivityManager.CONNECTIVITY_ACTION and there is some connection established. |
void |
onConnectionLost(android.content.Context context,
Connection.ConnectionType type)
Invoked whenever registered
ConnectionStateReceiver receives an Intent for the
ConnectivityManager.CONNECTIVITY_ACTION and there is no connection available. |
void onConnectionEstablished(android.content.Context context,
Connection.ConnectionType type,
android.net.NetworkInfo info)
ConnectionStateReceiver revives an Intent for the
ConnectivityManager.CONNECTIVITY_ACTION and there is some connection established.
Note: this is also fired while connection receiver is being registered via
Connection.registerConnectionReceiver(Context) and there is currently established some connection.
context - Current application context.type - Type of the connection which was just now established or was already established
while this callback was being registered.info - Info about the current established connection.void onConnectionLost(android.content.Context context,
Connection.ConnectionType type)
ConnectionStateReceiver receives an Intent for the
ConnectivityManager.CONNECTIVITY_ACTION and there is no connection available.
Note: this is also fired while connection receiver is being registered via
Connection.registerConnectionReceiver(Context) and there isn't currently any connection available.
context - Current application context.type - Type of the connection which the Android device just lost or UNAVAILABLE
if there was no connection available while this callback was being registered.