IKVM11  11
Java SE 11 Virtual Machine for .NET
Loading...
Searching...
No Matches
IKVM.Runtime.Util.Java.Net.InetSocketAddressExtensions Class Reference

Extension methods for working with Internet Socket Addresses. More...

Static Public Member Functions

static IPEndPoint ToIPEndpoint (this global::java.net.InetSocketAddress self)
 Gets a IPEndPoint for the given global::java.net.InetSocketAddress.
 
static global::java.net.InetSocketAddress ToInetSocketAddress (this IPEndPoint endpoint)
 Gets a global::java.net.InetSocketAddress for the given IPEndPoint.
 

Detailed Description

Extension methods for working with Internet Socket Addresses.

Definition at line 9 of file InetSocketAddressExtensions.cs.

Member Function Documentation

◆ ToInetSocketAddress()

static global.java.net.InetSocketAddress IKVM.Runtime.Util.Java.Net.InetSocketAddressExtensions.ToInetSocketAddress ( this IPEndPoint endpoint)
static

Gets a global::java.net.InetSocketAddress for the given IPEndPoint.

Parameters
endpoint
Returns

Definition at line 32 of file InetSocketAddressExtensions.cs.

33 {
34 return endpoint != null ? new java.net.InetSocketAddress(endpoint.Address.ToInetAddress(endpoint.Address.ToString()), endpoint.Port) : null;
35 }

◆ ToIPEndpoint()

static IPEndPoint IKVM.Runtime.Util.Java.Net.InetSocketAddressExtensions.ToIPEndpoint ( this global.java.net.InetSocketAddress self)
static

Gets a IPEndPoint for the given global::java.net.InetSocketAddress.

Parameters
self
Returns

Definition at line 19 of file InetSocketAddressExtensions.cs.

20 {
21 if (self == null)
22 return null;
23 else
24 return new IPEndPoint(self.getAddress().ToIPAddress(), self.getPort());
25 }

The documentation for this class was generated from the following file: