IpAddr
case V4(Ipv4Addr)
case V6(Ipv6Addr)
Represents an IP address.
Definitions
def fromBytes(l: List[Int8]): IpAddr
SourceConverts a List[Int8]
into IpAddr
an Ipv4 is 4 bytes and Ipv6 is 16 bytes
def fromString(s: String): Option[IpAddr]
SourceAttempts to parse the given String s
as an IpAddr
.
Returns Some(addr)
if the string was successfully parsed. Otherwise returns None
.
def toBytes(ip: IpAddr): Vector[Int8]
SourceConverts an IpAddr
into an Vector[Int8]
an Ipv4 is 4 bytes and Ipv6 is 16 bytes