ServerSocket.LocalPort Property

Definition

Returns the port number on which this socket is listening.

public virtual int LocalPort { [Android.Runtime.Register("getLocalPort", "()I", "GetGetLocalPortHandler")] get; }
[<get: Android.Runtime.Register("getLocalPort", "()I", "GetGetLocalPortHandler")>]
member this.LocalPort : int

Property Value

Int32

the port number to which this socket is listening or -1 if the socket is not bound yet.

Attributes

Remarks

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

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