public static class IPAddressConverter.DefaultAddressConverter extends Object implements IPAddressConverter
IPAddressConverter.DefaultAddressConverter
Constructor and Description |
---|
DefaultAddressConverter() |
Modifier and Type | Method and Description |
---|---|
boolean |
isIPv4Convertible(IPAddress address)
returns whether the address is IPv4 or can be converted to IPv4.
|
boolean |
isIPv6Convertible(IPAddress address)
returns whether the address is IPv6 or can be converted to IPv6.
|
IPv4Address |
toIPv4(IPAddress address)
If the given address is IPv4, or can be converted to IPv4, returns that
IPv4Address . |
IPv6Address |
toIPv6(IPAddress address)
If the given address is IPv6, or can be converted to IPv6, returns that
IPv6Address . |
public IPv4Address toIPv4(IPAddress address)
IPv4Address.IPv4AddressConverter
IPv4Address
. Otherwise, returns null.toIPv4
in interface IPv4Address.IPv4AddressConverter
public IPv6Address toIPv6(IPAddress address)
IPv6Address.IPv6AddressConverter
IPv6Address
. Otherwise, returns null.toIPv6
in interface IPv6Address.IPv6AddressConverter
public boolean isIPv4Convertible(IPAddress address)
IPAddressConverter
IPv4Address.IPv4AddressConverter.toIPv4(IPAddress)
returns non-null.isIPv4Convertible
in interface IPAddressConverter
public boolean isIPv6Convertible(IPAddress address)
IPAddressConverter
IPv6Address.IPv6AddressConverter.toIPv6(IPAddress)
returns non-null.isIPv6Convertible
in interface IPAddressConverter