java.net.InterfaceAddress
This class represents a Network Interface address. In short, it's an IP address, a subnet mask, and a broadcast address when the address is an IPv4 one. An IP address and a network prefix length in the case of an IPv6 address.
Some methods of InterfaceAddress class
equals(Object): This method compares this object against the specified object.
getAddress(): This method returns an InetAddress for this address.
getBroadcast(): This method returns an InetAddress for the broadcast address for this InterfaceAddress.
getNetworkPrefixLength(): This method returns the network prefix length for this address.
hashCode(): This method returns a hashcode for this Interface address.
toString(): This method converts this Interface address to a String. The string returned is of the form: InetAddress / prefix-length [ broadcast address ].
No comments:
Post a Comment