SelectableChannel.KeyFor(Selector) 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
检索表示通道使用给定选择器的注册的密钥。
[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
参数
- sel
- Selector
选择器
返回
上次向给定选择器注册此通道时返回的密钥,或者 null 此通道当前未向该选择器注册
- 特性
注解
检索表示通道使用给定选择器的注册的密钥。
适用于 . 的 java.nio.channels.SelectableChannel.keyFor(java.nio.channels.Selector)Java 文档
本页的某些部分是根据 Android 开放源代码项目创建和共享的工作进行的修改,并根据 Creative Commons 2.5 属性许可证中所述的术语使用。