Sdílet prostřednictvím


ServerSocket.Channel Property

Definition

Returns the unique java.nio.channels.ServerSocketChannel object associated with this socket, if any.

public virtual Java.Nio.Channels.ServerSocketChannel? Channel { [Android.Runtime.Register("getChannel", "()Ljava/nio/channels/ServerSocketChannel;", "GetGetChannelHandler")] get; }
[<get: Android.Runtime.Register("getChannel", "()Ljava/nio/channels/ServerSocketChannel;", "GetGetChannelHandler")>]
member this.Channel : Java.Nio.Channels.ServerSocketChannel

Property Value

the server-socket channel associated with this socket, or null if this socket was not created for a channel

Attributes

Remarks

Returns the unique java.nio.channels.ServerSocketChannel object associated with this socket, if any.

A server socket will have a channel if, and only if, the channel itself was created via the java.nio.channels.ServerSocketChannel#open ServerSocketChannel.open method.

Added in 1.4.

Java documentation for java.net.ServerSocket.getChannel().

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