IP::Address::IPv6
Inherits IP::Address < Comparable < Comparable < Struct < Value < Object
Constants
Constructors
Constructs a new IP::Address::IPv6 from the contents of a String. Expects an
address in the standard presentation form XXXX:XXXX:XXXX:XXXX:XXXX:XXXX:XXXX:XXXX
or in the compressed from similar to XXXX:XXXX::XXXX:XXXX:XXXX.
Raises: MalformedError when the input is malformed.
Constructs a new IP::Address::IPv6 from a SockaddrIn6*.
TODO: Significant testing nessissary.
Class methods
Constructs a new IP::Address::IPv6 from the contents of a String. Expects an
address in the standard presentation form XXXX:XXXX:XXXX:XXXX:XXXX:XXXX:XXXX:XXXX
or in the compressed from similar to XXXX:XXXX::XXXX:XXXX:XXXX.
Returns nil when the input is malformed.
Instance methods
Returns the requested group from the address.
Raises OutOfBoundsError if the requested group is not [0..7].
Appends the presentation representation of the address to the given IO.
Returns the presentation representation of the address as a String.
Produces the c sockaddr_in6 struct required by bind, connect, sendto, and sendmsg.
Note: Unix Network Programming: Volume 1, 3rd Edition, p.71-72
- sin6_len: default size of this struct is 28 bytes.
- sin_zero: is unused.
TODO: Set correct scope id