IPv6 utilities.
For the moment, it only contains function to canonicalize IPv6 address into RFC 5952 form.
| Modifier and Type | Field and Description |
|---|---|
| private static final int | |
| private static final int |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public static String | |
| pack-priv static boolean | Returns: true, if input string contains only hex digits and at least two colons, before '.' or '%' characterAny string or null input)Heuristic check if string might be an IPv6 address. |
| MAX_GROUP_LENGTH | back to summary |
|---|---|
| private static final int MAX_GROUP_LENGTH | |
| MAX_NUMBER_OF_GROUPS | back to summary |
|---|---|
| private static final int MAX_NUMBER_OF_GROUPS | |
| IPv6Utils | back to summary |
|---|---|
| public IPv6Utils() | |
| canonize | back to summary |
|---|---|
| public static String canonize(String ipv6Address) throws IllegalArgumentException Convert IPv6 address into RFC 5952 form. E.g. 2001:db8:0:1:0:0:0:1 -> 2001:db8:0:1::1 Method is null safe, and if IPv4 address or host name is passed to the method it is returned without any processing. Method also supports IPv4 in IPv6 (e.g. 0:0:0:0:0:ffff:192.0.2.1 -> ::ffff:192.0.2.1), and zone ID (e.g. fe80:0:0:0:f0f0:c0c0:1919:1234%4 -> fe80::f0f0:c0c0:1919:1234%4). The behaviour of this method is undefined if an invalid IPv6 address is passed in as input.
| |
| mayBeIPv6Address | back to summary |
|---|---|
| pack-priv static boolean mayBeIPv6Address(String input) Heuristic check if string might be an IPv6 address.
| |