public final class IPv6Network extends IPv6AddressRange
Modifier and Type | Field and Description |
---|---|
static IPv6Network |
LINK_LOCAL_NETWORK |
static IPv6Network |
MULTICAST_NETWORK |
static IPv6Network |
SITE_LOCAL_NETWORK |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o) |
static IPv6Network |
fromAddressAndMask(IPv6Address address,
IPv6NetworkMask networkMask)
Create an IPv6 network from an IPv6Address and an IPv6NetworkMask
|
static IPv6Network |
fromString(String string)
Create an IPv6 network from its String representation.
|
static IPv6Network |
fromTwoAddresses(IPv6Address one,
IPv6Address two)
Create an IPv6 network from the two addresses within the network.
|
IPv6NetworkMask |
getNetmask() |
int |
hashCode() |
Iterator<IPv6Network> |
split(IPv6NetworkMask size)
Split a network in smaller subnets of a given size.
|
String |
toLongString() |
String |
toString() |
public static final IPv6Network MULTICAST_NETWORK
public static final IPv6Network SITE_LOCAL_NETWORK
public static final IPv6Network LINK_LOCAL_NETWORK
public static IPv6Network fromAddressAndMask(IPv6Address address, IPv6NetworkMask networkMask)
address
- IPv6 address (the network address or any other address within the network)networkMask
- IPv6 network maskpublic static IPv6Network fromTwoAddresses(IPv6Address one, IPv6Address two)
one
- address onetwo
- address two, should be bigger than address onepublic static IPv6Network fromString(String string)
string
- string representationpublic Iterator<IPv6Network> split(IPv6NetworkMask size)
size
- size (expressed as IPv6NetworkMask
) of the subnetsIllegalArgumentException
- if the requested size is bigger than the original sizepublic String toString()
toString
in class IPv6AddressRange
public String toLongString()
toLongString
in class IPv6AddressRange
toString
but without using shorthand notations for addressespublic boolean equals(Object o)
equals
in class IPv6AddressRange
public int hashCode()
hashCode
in class IPv6AddressRange
public IPv6NetworkMask getNetmask()
Copyright © 2013. All Rights Reserved.