public static enum IpAddressUtils.IpTypePreference extends Enum<IpAddressUtils.IpTypePreference>
Enum.EnumDesc<E extends Enum<E>>
Enum Constant and Description |
---|
ANY_IPV4_PREF
Any of IPv4 or IPv6 addresses are acceptable in the returned value,
but IPv4 address is preferred over IPv6.
|
ANY_IPV6_PREF
Any of IPv4 or IPv6 addresses are acceptable in the returned value,
but IPv6 address is preferred over IPv4.
|
ANY_JDK_PREF
Any of IPv4 or IPv6 addresses are acceptable in the returned value,
but their internal preference is determined by the setting in the
JDK, namely the
java.net.preferIPv6Addresses system property. |
IPV4_ONLY
Only IPv4 address(es) in the returned value.
|
IPV6_ONLY
Only IPv6 address(es) in the returned value.
|
Modifier and Type | Method and Description |
---|---|
static IpAddressUtils.IpTypePreference |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static IpAddressUtils.IpTypePreference[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final IpAddressUtils.IpTypePreference IPV4_ONLY
public static final IpAddressUtils.IpTypePreference IPV6_ONLY
public static final IpAddressUtils.IpTypePreference ANY_IPV4_PREF
public static final IpAddressUtils.IpTypePreference ANY_IPV6_PREF
public static final IpAddressUtils.IpTypePreference ANY_JDK_PREF
java.net.preferIPv6Addresses
system property.
If this property is true
then using this preference will be
exactly as IpAddressUtils.IpTypePreference.ANY_IPV6_PREF
, if false
it will be
exactly as IpAddressUtils.IpTypePreference.ANY_IPV4_PREF
.public static IpAddressUtils.IpTypePreference[] values()
public static IpAddressUtils.IpTypePreference valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null