public class NetworkInterface extends Object implements Serializable, Cloneable
Describes a gateway's network interface.
Constructor and Description |
---|
NetworkInterface() |
Modifier and Type | Method and Description |
---|---|
NetworkInterface |
clone() |
boolean |
equals(Object obj) |
String |
getIpv4Address()
The Internet Protocol version 4 (IPv4) address of the interface.
|
String |
getIpv6Address()
The Internet Protocol version 6 (IPv6) address of the interface.
|
String |
getMacAddress()
The Media Access Control (MAC) address of the interface.
|
int |
hashCode() |
void |
setIpv4Address(String ipv4Address)
The Internet Protocol version 4 (IPv4) address of the interface.
|
void |
setIpv6Address(String ipv6Address)
The Internet Protocol version 6 (IPv6) address of the interface.
|
void |
setMacAddress(String macAddress)
The Media Access Control (MAC) address of the interface.
|
String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
NetworkInterface |
withIpv4Address(String ipv4Address)
The Internet Protocol version 4 (IPv4) address of the interface.
|
NetworkInterface |
withIpv6Address(String ipv6Address)
The Internet Protocol version 6 (IPv6) address of the interface.
|
NetworkInterface |
withMacAddress(String macAddress)
The Media Access Control (MAC) address of the interface.
|
public void setIpv4Address(String ipv4Address)
The Internet Protocol version 4 (IPv4) address of the interface.
ipv4Address
- The Internet Protocol version 4 (IPv4) address of the interface.public String getIpv4Address()
The Internet Protocol version 4 (IPv4) address of the interface.
public NetworkInterface withIpv4Address(String ipv4Address)
The Internet Protocol version 4 (IPv4) address of the interface.
ipv4Address
- The Internet Protocol version 4 (IPv4) address of the interface.public void setMacAddress(String macAddress)
The Media Access Control (MAC) address of the interface.
macAddress
- The Media Access Control (MAC) address of the interface.
public String getMacAddress()
The Media Access Control (MAC) address of the interface.
public NetworkInterface withMacAddress(String macAddress)
The Media Access Control (MAC) address of the interface.
macAddress
- The Media Access Control (MAC) address of the interface.
public void setIpv6Address(String ipv6Address)
The Internet Protocol version 6 (IPv6) address of the interface. Currently not supported.
ipv6Address
- The Internet Protocol version 6 (IPv6) address of the interface.
Currently not supported.public String getIpv6Address()
The Internet Protocol version 6 (IPv6) address of the interface. Currently not supported.
public NetworkInterface withIpv6Address(String ipv6Address)
The Internet Protocol version 6 (IPv6) address of the interface. Currently not supported.
ipv6Address
- The Internet Protocol version 6 (IPv6) address of the interface.
Currently not supported.public String toString()
toString
in class Object
Object.toString()
public NetworkInterface clone()
Copyright © 2015. All rights reserved.