ipaddr 2.1.0 copy "ipaddr: ^2.1.0" to clipboard
ipaddr: ^2.1.0 copied to clipboard

This library is used to create/poke/manipulate IPv4 and IPv6 addresses and networks.

ipaddr #

test and lint pub doc

Usage #

import 'package:ipaddr/ipaddr.dart' as ipaddr;

main() {
  var address = ipaddr.IPv4Address('192.168.10.10');
  var network = ipaddr.IPv4Network('192.168.10.0/24');
  if (network.addresses.contains(address)) {
    print('$address is included $network'); // 192.168.10.10 is included 192.168.10.0/24
  }
}

Thanks #

Inspired by python ipaddress lib.

License #

MIT

3
likes
140
pub points
77%
popularity

Publisher

unverified uploader

This library is used to create/poke/manipulate IPv4 and IPv6 addresses and networks.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (LICENSE)

More

Packages that depend on ipaddr