Builder
class Builder
kotlin.Any | |
↳ | android.net.ipsec.ike.IkeSessionConfiguration.Builder |
This class can be used to incrementally construct a IkeSessionConfiguration
.
Except for testing, IKE library users normally do not instantiate IkeSessionConfiguration
themselves but instead get a reference via IkeSessionCallback
Summary
Public constructors | |
---|---|
Builder(ikeConnInfo: IkeSessionConnectionInfo) Constructs a Builder. |
Public constructors
Builder
Builder(ikeConnInfo: IkeSessionConnectionInfo)
Constructs a Builder.
Parameters | |
---|---|
ikeConnInfo |
IkeSessionConnectionInfo: the connection information This value cannot be null . |
Public methods
addIkeExtension
fun addIkeExtension(extensionType: Int): IkeSessionConfiguration.Builder
Marks an IKE extension as enabled for the IkeSessionConfiguration
being built.
Parameters | |
---|---|
extensionType |
Int: the enabled extension Value is android.net.ipsec.ike.IkeSessionConfiguration#EXTENSION_TYPE_FRAGMENTATION , or android.net.ipsec.ike.IkeSessionConfiguration#EXTENSION_TYPE_MOBIKE |
Return | |
---|---|
IkeSessionConfiguration.Builder |
Builder this, to facilitate chaining This value cannot be null . |
addRemoteVendorId
fun addRemoteVendorId(remoteVendorId: ByteArray): IkeSessionConfiguration.Builder
Adds a remote vendor ID for the IkeSessionConfiguration
being built.
Parameters | |
---|---|
remoteVendorId |
ByteArray: a remote vendor ID This value cannot be null . |
Return | |
---|---|
IkeSessionConfiguration.Builder |
Builder this, to facilitate chaining This value cannot be null . |
build
fun build(): IkeSessionConfiguration
Constructs an IkeSessionConfiguration
instance.
Return | |
---|---|
IkeSessionConfiguration |
This value cannot be null . |
clearIkeExtensions
fun clearIkeExtensions(): IkeSessionConfiguration.Builder
Clear all enabled IKE extensions from the IkeSessionConfiguration
being built.
Return | |
---|---|
IkeSessionConfiguration.Builder |
Builder this, to facilitate chaining This value cannot be null . |
clearRemoteApplicationVersion
fun clearRemoteApplicationVersion(): IkeSessionConfiguration.Builder
Clears the remote application version from the IkeSessionConfiguration
being built.
Return | |
---|---|
IkeSessionConfiguration.Builder |
Builder this, to facilitate chaining This value cannot be null . |
clearRemoteVendorIds
fun clearRemoteVendorIds(): IkeSessionConfiguration.Builder
Clears all remote vendor IDs from the IkeSessionConfiguration
being built.
Return | |
---|---|
IkeSessionConfiguration.Builder |
Builder this, to facilitate chaining This value cannot be null . |
setEapInfo
fun setEapInfo(eapInfo: EapInfo?): IkeSessionConfiguration.Builder
Sets EapInfo for the IkeSessionConfiguration
being built.
Parameters | |
---|---|
eapInfo |
EapInfo?: This value may be null . |
Return | |
---|---|
IkeSessionConfiguration.Builder |
Builder this, to facilitate chaining This value cannot be null . |
setRemoteApplicationVersion
fun setRemoteApplicationVersion(remoteApplicationVersion: String): IkeSessionConfiguration.Builder
Sets the remote application version for the IkeSessionConfiguration
being built.
Parameters | |
---|---|
remoteApplicationVersion |
String: the remote application version. Defaults to an empty string. This value cannot be null . |
Return | |
---|---|
IkeSessionConfiguration.Builder |
Builder this, to facilitate chaining This value cannot be null . |