|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.kuka.common.NetUtil
public final class NetUtil
A class that implements some common used classes for network interfaces.
| Method Summary | |
|---|---|
static List<InetAddress> |
determineAddresses()
Determines all address on all network interfaces of the PC. |
static List<Inet4Address> |
getLocalIPAdresses()
Gets all IP-addresses of the local system. |
static Inet4Address |
getMatchingLocalIPAdress(List<Inet4Address> availableAddresses,
String remoteAddress,
String netmask)
Gets a specific IP-address of the local system. |
static boolean |
isLocalHost(String ipAdress)
Returns true if the specified IP address is a local host address. |
static boolean |
isReachable(String ip,
int timeout)
Deprecated. Set to deprecated because this method does not work properly in Windows! (see bug 11950) |
static boolean |
isReachableByNetworkSharePort(String host,
int timeout)
Indicates whether the specified host is reachable (ping) by Server Message Block (SMB) TCP port 445, used for network file sharing. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
@Deprecated
public static boolean isReachable(String ip,
int timeout)
ip - IP address to check.timeout - timeout for the check
public static boolean isReachableByNetworkSharePort(String host,
int timeout)
host - host name or IP address to check.timeout - timeout for the check in milliseconds
public static List<InetAddress> determineAddresses()
throws Exception
Exception - If an error occurs.
public static Inet4Address getMatchingLocalIPAdress(List<Inet4Address> availableAddresses,
String remoteAddress,
String netmask)
throws SocketException
availableAddresses - the addresses in which the matching IP address should be searched for.remoteAddress - remote IP address for compatibility check.netmask - network mask for compatibility check.
SocketException - socket error
public static List<Inet4Address> getLocalIPAdresses()
throws SocketException
SocketException - socket errorpublic static boolean isLocalHost(String ipAdress)
ipAdress - the IP address that should be checked if it is the local host
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||