commit | 475085b9870c49085f4b5238d84d6e5d5750f31c | [log] [tgz] |
---|---|---|
author | Lorenzo Colitti <lorenzo@google.com> | Tue Mar 10 01:32:40 2015 +0900 |
committer | Lorenzo Colitti <lorenzo@google.com> | Mon Mar 16 16:07:36 2015 +0900 |
tree | a3c82c5f0ff94904da15a7281f883d8a7c50e793 | |
parent | e08a3977a0afdcc5d935993e9ca4a5eaf769e523 [diff] |
Add two utility methods for IPv4 netmasks. 1. Add a validating method to convert a netmask to a prefix length. 2. Add a function to get the implicit netmask of an IPv4 address. 3. Add a unit test. Bug: 19704592 Change-Id: Icb9f58d3903ea01df9e3720383c9bd5db6dd8f26