Sdílet prostřednictvím


SelectableChannel.KeyFor(Selector) Method

Definition

Retrieves the key representing the channel's registration with the given selector.

[Android.Runtime.Register("keyFor", "(Ljava/nio/channels/Selector;)Ljava/nio/channels/SelectionKey;", "GetKeyFor_Ljava_nio_channels_Selector_Handler")]
public abstract Java.Nio.Channels.SelectionKey? KeyFor (Java.Nio.Channels.Selector? sel);
[<Android.Runtime.Register("keyFor", "(Ljava/nio/channels/Selector;)Ljava/nio/channels/SelectionKey;", "GetKeyFor_Ljava_nio_channels_Selector_Handler")>]
abstract member KeyFor : Java.Nio.Channels.Selector -> Java.Nio.Channels.SelectionKey

Parameters

sel
Selector

The selector

Returns

The key returned when this channel was last registered with the given selector, or null if this channel is not currently registered with that selector

Attributes

Remarks

Retrieves the key representing the channel's registration with the given selector.

Java documentation for java.nio.channels.SelectableChannel.keyFor(java.nio.channels.Selector).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to