net.Ipv6Address Extends goog.net.IpAddress
Takes a string or a number and returns an IPv6 Address. This constructor accepts strings and instance of goog.math.Integer. If you pass a goog.math.Integer, make sure that its sign is set to positive.

Inheritance

Constructor

goog.net.Ipv6Address(address)

Parameters

address : (string | !goog.math.Integer)
The address to store.

Instance Methods

Public Protected Private
getMappedIpv4Address() goog.net.Ipv4Address
Will return the mapped IPv4 address in this IPv6 address.
Returns: goog.net.Ipv4Address  an IPv4 or null.
code »
isMappedIpv4Address() boolean
No description.
Returns: boolean  true if the IPv6 contains a mapped IPv4.
code »
toString()
No description.
code »
toUriString()
No description.
code »
equals(other) boolean
No description.
Arguments:
other : !goog.net.IpAddress
The other IP Address.
Returns: boolean  true if the IP Addresses are equal.
code »
getVersion() number
No description.
Returns: number  The IP Address version.
code »
toInteger() goog.math.Integer
No description.
Returns: goog.math.Integer  The IP Address, as an Integer.
code »
toString() string
No description.
Returns: string  The IP Address, as a string.
code »
toUriString() string
No description.
Returns: string  The IP Address, as an URI string following RFC 3986.
code »

Instance Properties

constructor :
No description.
Code »
ipStr_ :
The IPAddress, as string.
Code »
The IP Address.
Code »
version_ :
The IP Address version.
Code »

Static Methods

goog.net.Ipv6Address.compress_(hextets) !Array.<string>
This method is in charge of compressing an expanded IPv6 array of hextets.
Arguments:
hextets : !Array.<string>
The array of hextet.
Returns: !Array.<string>  The compressed version of this array.
code »
goog.net.Ipv6Address.dottedQuadtoHextets_(quads) !Array.<string>
This method will convert an IPv4 to a list of 2 hextets. For instance, 1.2.3.4 will be converted to ['0102', '0304'].
Arguments:
quads : string
An IPv4 as a string.
Returns: !Array.<string>  A list of 2 hextets.
code »
goog.net.Ipv6Address.explode_(address) !Array.<string>
This method is in charge of expanding/exploding an IPv6 string from its compressed form.
Arguments:
address : !Array.<string>
An IPv6 address split around '::'.
Returns: !Array.<string>  The expanded version of the IPv6.
code »

Static Properties

goog.net.Ipv6Address.MAX_ADDRESS_ : goog.math.Integer
The Maximum address possible for IPv6.
Code »
goog.net.Ipv6Address.MAX_HEXTET_VALUE_ : goog.math.Integer
The maximum value of a hextet.
Code »
goog.net.Ipv6Address.MAX_NETMASK_LENGTH :
The Maximum length for a netmask (aka, the number of bits for IPv6).
Code »
goog.net.Ipv6Address.REGEX_ :
Regular expression matching all allowed chars for an IPv6.
Code »
goog.net.Ipv6Address.superClass_ :
No description.
Code »

Package net

Package Reference