Skip to content
Ron Hashimoto edited this page Aug 4, 2016 · 4 revisions

IPv4Address represents an Internet Protocol version 4 address.

Usage

import IPv4Address from 'dripcap/ipv4/addr';

let addr = new IPv4Address('127.0.0.1');

Reference

Methods

#constructor (String addr) -> IPv4Address

Constructs a IPv4Address from the addr.

#constructor (Buffer addr) -> IPv4Address

Constructs a IPv4Address the addr. addr.length must be 4.

#equals (IPv4Address addr) -> Boolean

Returns true if this and the given IPv4Address has the same address.

#toString () -> String

Returns a string representing the address.

#toJSON () -> String

JSON serializer interface.

#toMsgpack () -> Array

MessagePack serializer interface.

Clone this wiki locally