java.net
Class VMNetworkInterface

java.lang.Object
java.net.VMNetworkInterface
- final class VMNetworkInterface
- extends java.lang.Object
This class models a network interface on the host computer. A network
interface contains a name (typically associated with a specific
hardware adapter) and a list of addresses that are bound to it.
For example, an ethernet interface may be named "eth0" and have the
address 192.168.1.101 assigned to it.
- Since:
- 1.4
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
VMNetworkInterface
VMNetworkInterface()
getInterfaces
public static java.util.Vector getInterfaces()
throws SocketException
- Returns a Vector of InetAddresses. The returned value will be
'condensed', meaning that all elements with the same interface
name will be collapesed into one InetAddress for that name
containing all addresses before the returning the result to the
user. This means the native method can be implemented in a naive
way mapping each address/interface to a name even if that means
that the Vector contains multiple InetAddresses with the same
interface name.