Stay organized with collections
Save and categorize content based on your preferences.
IkeNetworkLostException
class IkeNetworkLostException : IkeNonProtocolException
IkeNetworkLostException is returned to the caller via android.net.ipsec.ike.IkeSessionCallback#onError(android.net.ipsec.ike.exceptions.IkeException)
if the underlying Network for the was lost with no alternatives.
This Exception corresponds to android.net.ConnectivityManager.NetworkCallback#onLost(android.net.Network)
being invoked for the specified underlying Network.
When the caller receives this Exception, they must either:
- set a new underlying Network for the corresponding IkeSession (MOBIKE must be enabled and the IKE Session must have started with a caller-configured Network), or
- wait for a new underlying Network to become available (MOBIKE must be enabled and the IKE Session must be tracking the System default Network), or
- close the corresponding IkeSession.
Summary
Public constructors |
Constructs an IkeNetworkLostException to indicate the specified Network was lost.
|
Public methods |
Network |
Returns the IkeSession's underlying Network that was lost.
|
Public constructors
IkeNetworkLostException
IkeNetworkLostException(network: Network)
Constructs an IkeNetworkLostException to indicate the specified Network was lost.
Parameters |
network |
Network: This value cannot be null . |
Public methods
getNetwork
fun getNetwork(): Network
Returns the IkeSession's underlying Network that was lost.
Return |
Network |
This value cannot be null . |
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-02-10 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-02-10 UTC."],[],[],null,["# IkeNetworkLostException\n\nAdded in [API level 31](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)\n\nIkeNetworkLostException\n=======================\n\n*** ** * ** ***\n\nKotlin \\|[Java](/reference/android/net/ipsec/ike/exceptions/IkeNetworkLostException \"View this page in Java\") \n\n```\nclass IkeNetworkLostException : IkeNonProtocolException\n```\n\n|---|---|---|---|---|---------------------------------------------------------------|\n| [kotlin.Any](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html) ||||||\n| ↳ | [kotlin.Throwable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html) |||||\n| | ↳ | [java.lang.Exception](../../../../../java/lang/Exception.html#) ||||\n| | | ↳ | [android.net.ipsec.ike.exceptions.IkeException](/reference/kotlin/android/net/ipsec/ike/exceptions/IkeException) |||\n| | | | ↳ | [android.net.ipsec.ike.exceptions.IkeNonProtocolException](/reference/kotlin/android/net/ipsec/ike/exceptions/IkeNonProtocolException) ||\n| | | | | ↳ | [android.net.ipsec.ike.exceptions.IkeNetworkLostException](#) |\n\nIkeNetworkLostException is returned to the caller via [android.net.ipsec.ike.IkeSessionCallback#onError(android.net.ipsec.ike.exceptions.IkeException)](../IkeSessionCallback.html#onError(android.net.ipsec.ike.exceptions.IkeException)) if the underlying Network for the was lost with no alternatives.\n\nThis Exception corresponds to [android.net.ConnectivityManager.NetworkCallback#onLost(android.net.Network)](../../../ConnectivityManager.NetworkCallback.html#onLost(android.net.Network)) being invoked for the specified underlying Network.\n\nWhen the caller receives this Exception, they must either:\n\n- set a new underlying Network for the corresponding IkeSession (MOBIKE must be enabled and the IKE Session must have started with a caller-configured Network), or\n- wait for a new underlying Network to become available (MOBIKE must be enabled and the IKE Session must be tracking the System default Network), or\n - Note: if the maximum retransmission time is encountered while waiting, the IKE Session will close. If this occurs, the caller will be notified via [android.net.ipsec.ike.IkeSessionCallback#onClosedWithException(android.net.ipsec.ike.exceptions.IkeException)](../IkeSessionCallback.html#onClosedWithException(android.net.ipsec.ike.exceptions.IkeException)).\n- close the corresponding IkeSession.\n\nSummary\n-------\n\n| Public constructors ||\n|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---|\n| [IkeNetworkLostException](#IkeNetworkLostException(android.net.Network))`(`network:` `[Network](../../../Network.html#)`)` Constructs an IkeNetworkLostException to indicate the specified Network was lost. |\n\n| Public methods ||\n|-----------------------------------|--------------------------------------------------------------------------------------------|\n| [Network](../../../Network.html#) | [getNetwork](#getNetwork())`()` Returns the IkeSession's underlying Network that was lost. |\n\nPublic constructors\n-------------------\n\n### IkeNetworkLostException\n\nAdded in [API level 31](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nIkeNetworkLostException(network: Network)\n```\n\nConstructs an IkeNetworkLostException to indicate the specified Network was lost.\n\n| Parameters ||\n|-----------|-----------------------------------------------------------------|\n| `network` | [Network](../../../Network.html#): This value cannot be `null`. |\n\nPublic methods\n--------------\n\n### getNetwork\n\nAdded in [API level 31](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nfun getNetwork(): Network\n```\n\nReturns the IkeSession's underlying Network that was lost.\n\n| Return ||\n|-----------------------------------|------------------------------|\n| [Network](../../../Network.html#) | This value cannot be `null`. |"]]