calrissian / mango

Common utilities for rapid application development
Apache License 2.0
17 stars 7 forks source link

Create utilities to parse CIDRs for both IPv4 and IPv6 formats #135

Closed eawagner closed 9 years ago

eawagner commented 9 years ago

A utility should provide at a minimum the network and broadcast addresses associated with the CIDR and should work for any valid bit mask for the given IP representation.

Additionally, as the mango IP domain objects are comparable, we should construct a Range object to hold these to allow us to get useful utilities provided by that class for determining if IPs fall within the CIDR range.

This functionality should be able to replace the CidrValueRangeIPv4 class to allow Issue #124 to be completed without loss of functionality.