Stay organized with collections
Save and categorize content based on your preferences.
IkeTrafficSelector
class IkeTrafficSelector
IkeTrafficSelector represents a Traffic Selector of a Child Session.
Traffic Selectors specify addresses that are acceptable within the IPsec SA.
Callers can propose IkeTrafficSelector
s when building a ChildSessionParams
and receive the negotiated IkeTrafficSelector
s via a ChildSessionConfiguration
.
Summary
Public constructors |
Construct an instance of IkeTrafficSelector for negotiating a Child Session.
|
Properties |
Int |
The largest port number allowed by this Traffic Selector.
|
InetAddress |
The largest address included in this Traffic Selector.
|
Int |
The smallest port number allowed by this Traffic Selector.
|
InetAddress |
The smallest address included in this Traffic Selector.
|
Public constructors
IkeTrafficSelector
IkeTrafficSelector(
startPort: Int,
endPort: Int,
startingAddress: InetAddress,
endingAddress: InetAddress)
Construct an instance of IkeTrafficSelector
for negotiating a Child Session.
Android platform does not support port-based routing. The port range negotiation is only informational.
Parameters |
startPort |
Int: the smallest port number allowed by this Traffic Selector. |
endPort |
Int: the largest port number allowed by this Traffic Selector. |
startingAddress |
InetAddress: the smallest address included in this Traffic Selector. This value cannot be null . |
endingAddress |
InetAddress: the largest address included in this Traffic Selector. This value cannot be null . |
Properties
endPort
val endPort: Int
The largest port number allowed by this Traffic Selector. Informational only.
endingAddress
val endingAddress: InetAddress
The largest address included in this Traffic Selector.
startPort
val startPort: Int
The smallest port number allowed by this Traffic Selector. Informational only.
startingAddress
val startingAddress: InetAddress
The smallest address included in this Traffic Selector.
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,["# IkeTrafficSelector\n\nAdded in [API level 31](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)\n\nIkeTrafficSelector\n==================\n\n*** ** * ** ***\n\nKotlin \\|[Java](/reference/android/net/ipsec/ike/IkeTrafficSelector \"View this page in Java\") \n\n```\nclass IkeTrafficSelector\n```\n\n|---|-----------------------------------------------|\n| [kotlin.Any](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html) ||\n| ↳ | [android.net.ipsec.ike.IkeTrafficSelector](#) |\n\nIkeTrafficSelector represents a Traffic Selector of a Child Session.\n\nTraffic Selectors specify addresses that are acceptable within the IPsec SA.\n\nCallers can propose [IkeTrafficSelector](#)s when building a [ChildSessionParams](/reference/kotlin/android/net/ipsec/ike/ChildSessionParams) and receive the negotiated [IkeTrafficSelector](#)s via a [ChildSessionConfiguration](/reference/kotlin/android/net/ipsec/ike/ChildSessionConfiguration).\n\nSummary\n-------\n\n| Public constructors ||\n|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---|\n| [IkeTrafficSelector](#IkeTrafficSelector(kotlin.Int,%20kotlin.Int,%20java.net.InetAddress,%20java.net.InetAddress))`(`startPort:` `[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`, `endPort:` `[Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html)`, `startingAddress:` `[InetAddress](../../../../java/net/InetAddress.html#)`, `endingAddress:` `[InetAddress](../../../../java/net/InetAddress.html#)`)` Construct an instance of [IkeTrafficSelector](#) for negotiating a Child Session. |\n\n| Properties ||\n|----------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------|\n| [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html) | [endPort](#endPort:kotlin.Int) The largest port number allowed by this Traffic Selector. |\n| [InetAddress](../../../../java/net/InetAddress.html#) | [endingAddress](#endingAddress:java.net.InetAddress) The largest address included in this Traffic Selector. |\n| [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html) | [startPort](#startPort:kotlin.Int) The smallest port number allowed by this Traffic Selector. |\n| [InetAddress](../../../../java/net/InetAddress.html#) | [startingAddress](#startingAddress:java.net.InetAddress) The smallest address included in this Traffic Selector. |\n\nPublic constructors\n-------------------\n\n### IkeTrafficSelector\n\nAdded in [API level 31](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nIkeTrafficSelector(\n startPort: Int, \n endPort: Int, \n startingAddress: InetAddress, \n endingAddress: InetAddress)\n```\n\nConstruct an instance of [IkeTrafficSelector](#) for negotiating a Child Session.\n\nAndroid platform does not support port-based routing. The port range negotiation is only informational.\n\n| Parameters ||\n|-------------------|---------------------------------------------------------------------------------------------------------------------------------------------|\n| `startPort` | [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html): the smallest port number allowed by this Traffic Selector. |\n| `endPort` | [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html): the largest port number allowed by this Traffic Selector. |\n| `startingAddress` | [InetAddress](../../../../java/net/InetAddress.html#): the smallest address included in this Traffic Selector. This value cannot be `null`. |\n| `endingAddress` | [InetAddress](../../../../java/net/InetAddress.html#): the largest address included in this Traffic Selector. This value cannot be `null`. |\n\nProperties\n----------\n\n### endPort\n\nAdded in [API level 31](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nval endPort: Int\n```\n\nThe largest port number allowed by this Traffic Selector. Informational only. \n\n### endingAddress\n\nAdded in [API level 31](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nval endingAddress: InetAddress\n```\n\nThe largest address included in this Traffic Selector. \n\n### startPort\n\nAdded in [API level 31](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nval startPort: Int\n```\n\nThe smallest port number allowed by this Traffic Selector. Informational only. \n\n### startingAddress\n\nAdded in [API level 31](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nval startingAddress: InetAddress\n```\n\nThe smallest address included in this Traffic Selector."]]