Creates a new IPv4 address from four octets.
The first octet.
The second octet.
The third octet.
The fourth octet.
Creates a new IPv4 address from an integer value.
The integer representation of the IPv4 address.
ReadonlyfamilyThe address family identifier for IPv4 addresses.
Static ReadonlyBITSThe number of bits in an IPv4 address.
Static ReadonlyBROADCASTThe broadcast address 255.255.255.255.
Static ReadonlyLOCALHOSTThe localhost address 127.0.0.1.
Static ReadonlyUNSPECIFIEDThe unspecified address 0.0.0.0.
Checks whether this address is in the benchmarking range.
true when the address is in 198.18.0.0/15, otherwise false.
Checks whether this address is the broadcast address.
true when the address is 255.255.255.255, otherwise false.
Checks whether this address is in a documentation-only range.
true for 192.0.2.0/24, 198.51.100.0/24, or 203.0.113.0/24; otherwise false.
Checks whether this address is globally reachable.
true when the address is not in any special non-global range.
Checks whether this address is link-local.
true when the address is in 169.254.0.0/16, otherwise false.
Checks whether this address is a loopback address.
true when the address is in 127.0.0.0/8, otherwise false.
Checks whether this address is a multicast address.
true when the address is in 224.0.0.0/4, otherwise false.
Checks whether this address is in a private-use range.
true for 10.0.0.0/8, 172.16.0.0/12, or 192.168.0.0/16; otherwise false.
Checks whether this address is in the reserved range.
true when the address is in 240.0.0.0/4 except the broadcast address.
Checks whether this address is in the shared Carrier-Grade NAT range.
true when the address is in 100.64.0.0/10, otherwise false.
Encodes this address to a 4-byte buffer.
OptionallittleEndian: booleanAn ArrayBuffer containing the IPv4 integer value.
Converts this address to an IPv4-compatible IPv6 address.
An IPv6 address in the form ::a.b.c.d.
Converts this address to an IPv4-mapped IPv6 address.
An IPv6 address in the form ::ffff:a.b.c.d.
StaticfromStaticfromCreates an IPv4 address from a 4-byte buffer.
OptionallittleEndian: booleanA successful IResult with an IPv4 address, or an error when the buffer cannot be read.
Represents an IPv4 address.
Example
Since
v0.0.1