| Modifier and Type | Class and Description |
|---|---|
| public static class | |
| public static class | |
| public static class |
| Access | Constructor and Description |
|---|---|
| public |
| SocketUtilsIPV6 | back to summary |
|---|---|
| public SocketUtilsIPV6() | |
| getIPV6Address | back to summary |
|---|---|
| public static String getIPV6Address(String ip) | |
| getIPV6NetMask | back to summary |
|---|---|
| public static String getIPV6NetMask(String ip) | |
| Modifier and Type | Field and Description |
|---|---|
| private long | |
| private long | |
| private static final int |
| Access | Constructor and Description |
|---|---|
| pack-priv | |
| private |
| Modifier and Type | Method and Description |
|---|---|
| public SocketUtilsIPV6. | |
| private int | |
| private int | |
| private String | |
| public SocketUtilsIPV6. | Returns: IPv6 addressstring representation string)Create an IPv6 address from its String representation. |
| private String | |
| public long | |
| public long | |
| private boolean | |
| public boolean | Returns: true if the address is an IPv4-mapped IPv6 addresses.Returns true if the address is an IPv4-mapped IPv6 address. |
| private boolean | |
| public SocketUtilsIPV6. | Returns: an address of which the last 128 - networkMask.asPrefixLength() bits are zeronetwork mask networkMaskMask the address with the given network mask. |
| public SocketUtilsIPV6. | Returns: an address of which the last 128 - networkMask.asPrefixLength() bits are onenetwork mask networkMaskCalculate the maximum address with the given network mask. |
| private SocketUtilsIPV6. | |
| public int | |
| public int | |
| public int | |
| public int | |
| private long[] | |
| private String | |
| private String | |
| pack-priv int[] | |
| public SocketUtilsIPV6. | |
| private String[] | |
| public InetAddress | |
| private String | |
| private short[] | |
| private String | |
| public String | Returns: String representation of the IPv6 addressOverrides java. Returns a string representation of the IPv6 address. |
| private long[] |
| highBits | back to summary |
|---|---|
| private long highBits | |
| lowBits | back to summary |
|---|---|
| private long lowBits | |
| N_SHORTS | back to summary |
|---|---|
| private static final int N_SHORTS | |
| IPv6Address | back to summary |
|---|---|
| pack-priv IPv6Address(long highBits, long lowBits) | |
| IPv6Address | back to summary |
|---|---|
| private IPv6Address() | |
| add | back to summary |
|---|---|
| public SocketUtilsIPV6. Addition. Will never overflow, but wraps around when the highest ip address has been reached.
| |
| countConsecutiveZeroes | back to summary |
|---|---|
| private int countConsecutiveZeroes(short[] shorts, int offset) | |
| countOccurrences | back to summary |
|---|---|
| private int countOccurrences(String haystack, char needle) | |
| expandShortNotation | back to summary |
|---|---|
| private String expandShortNotation(String string) | |
| fromString | back to summary |
|---|---|
| public SocketUtilsIPV6. Create an IPv6 address from its String representation. For example "1234:5678:abcd:0000:9876:3210:ffff:ffff" or "2001::ff" or even "::". IPv4-Mapped IPv6 addresses such as "::ffff:123.456.123.456" are also supported.
| |
| generateZeroes | back to summary |
|---|---|
| private String generateZeroes(int number) | |
| getHighBits | back to summary |
|---|---|
| public long getHighBits() | |
| getLowBits | back to summary |
|---|---|
| public long getLowBits() | |
| inHighRange | back to summary |
|---|---|
| private boolean inHighRange(int shortNumber) | |
| isIPv4Mapped | back to summary |
|---|---|
| public boolean isIPv4Mapped() Returns true if the address is an IPv4-mapped IPv6 address. In these addresses, the first 80 bits are zero, the next 16 bits are one, and the remaining 32 bits are the IPv4 address.
| |
| isLessThanUnsigned | back to summary |
|---|---|
| private boolean isLessThanUnsigned(long a, long b) | |
| maskWithNetworkMask | back to summary |
|---|---|
| public SocketUtilsIPV6. Mask the address with the given network mask.
| |
| maximumAddressWithNetworkMask | back to summary |
|---|---|
| public SocketUtilsIPV6. Calculate the maximum address with the given network mask.
| |
| mergeLongArrayIntoIPv6Address | back to summary |
|---|---|
| private SocketUtilsIPV6. | |
| numberOfLeadingOnes | back to summary |
|---|---|
| public int numberOfLeadingOnes() | |
| numberOfLeadingZeroes | back to summary |
|---|---|
| public int numberOfLeadingZeroes() | |
| numberOfTrailingOnes | back to summary |
|---|---|
| public int numberOfTrailingOnes() | |
| numberOfTrailingZeroes | back to summary |
|---|---|
| public int numberOfTrailingZeroes() | |
| parseStringArrayIntoLongArray | back to summary |
|---|---|
| private long[] parseStringArrayIntoLongArray(String[] strings) | |
| removeScope | back to summary |
|---|---|
| private String removeScope(String string) | |
| rewriteIPv4MappedNotation | back to summary |
|---|---|
| private String rewriteIPv4MappedNotation(String string) | |
| startAndLengthOfLongestRunOfZeroes | back to summary |
|---|---|
| pack-priv int[] startAndLengthOfLongestRunOfZeroes() | |
| subtract | back to summary |
|---|---|
| public SocketUtilsIPV6. Subtraction. Will never underflow, but wraps around when the lowest ip address has been reached.
| |
| toArrayOfShortStrings | back to summary |
|---|---|
| private String[] toArrayOfShortStrings() | |
| toInetAddress | back to summary |
|---|---|
| public InetAddress toInetAddress() throws UnknownHostException | |
| toIPv4MappedAddressString | back to summary |
|---|---|
| private String toIPv4MappedAddressString() | |
| toShortArray | back to summary |
|---|---|
| private short[] toShortArray() | |
| toShortHandNotationString | back to summary |
|---|---|
| private String toShortHandNotationString() | |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Returns a string representation of the IPv6 address. It will use shorthand notation and special notation for IPv4-mapped IPv6 addresses whenever possible. | |
| tryParseStringArrayIntoLongArray | back to summary |
|---|---|
| private long[] tryParseStringArrayIntoLongArray(String string, String longNotation) | |
| Modifier and Type | Field and Description |
|---|---|
| private SocketUtilsIPV6. | |
| private SocketUtilsIPV6. | |
| private SocketUtilsIPV6. | |
| private SocketUtilsIPV6. |
| Access | Constructor and Description |
|---|---|
| private | IPv6Network(SocketUtilsIPV6.
address address,network mask networkMaskConstruct from address and network mask. |
| private |
| Modifier and Type | Method and Description |
|---|---|
| public SocketUtilsIPV6. | Returns: IPv6 networkstring representation string)Create an IPv6 network from its String representation. |
| public SocketUtilsIPV6. | |
| private String | |
| private int |
| address | back to summary |
|---|---|
| private SocketUtilsIPV6. | |
| first | back to summary |
|---|---|
| private SocketUtilsIPV6. | |
| last | back to summary |
|---|---|
| private SocketUtilsIPV6. | |
| networkMask | back to summary |
|---|---|
| private SocketUtilsIPV6. | |
| IPv6Network | back to summary |
|---|---|
| private IPv6Network(SocketUtilsIPV6. Construct from address and network mask.
| |
| IPv6Network | back to summary |
|---|---|
| private IPv6Network() | |
| fromString | back to summary |
|---|---|
| public SocketUtilsIPV6. Create an IPv6 network from its String representation. For example "1234:5678:abcd:0:0:0:0:0/64" or "2001::ff/128".
| |
| getNetmask | back to summary |
|---|---|
| public SocketUtilsIPV6. | |
| parseNetworkAddress | back to summary |
|---|---|
| private String parseNetworkAddress(String string) | |
| parsePrefixLength | back to summary |
|---|---|
| private int parsePrefixLength(String string) | |
| Modifier and Type | Field and Description |
|---|---|
| private final int |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public SocketUtilsIPV6. | |
| public int |
| prefixLength | back to summary |
|---|---|
| private final int prefixLength | |
| IPv6NetworkMask | back to summary |
|---|---|
| pack-priv IPv6NetworkMask(int prefixLength) | |
| asAddress | back to summary |
|---|---|
| public SocketUtilsIPV6. | |
| asPrefixLength | back to summary |
|---|---|
| public int asPrefixLength() | |