summaryrefslogtreecommitdiff
path: root/core/java/android/net/IpPrefix.java
Commit message (Collapse)AuthorAgeFilesLines
* Move module sources to packages/ConnectivityRemi NGUYEN VAN2021-02-011-300/+0
| | | | | | | | | | | | | | Files that are planned to be part of the connectivity module are grouped in packages/Connectivity, so they can be built separately and moved in one operation with their history into packages/modules/Connectivity. This places the files in the existing framework-connectivity-sources filegroup instead of the current framework-core-sources filegroup. Both are used the same way in framework-non-updatable-sources. Bug: 171540887 Test: m Change-Id: I62d9d91574ace6f5c4624035d190260c3126b91e
* Remove @TestApi from @SystemApi symbolsAnton Hansson2020-10-191-3/+0
| | | | | | | | | | | | | | I ran these commands: cd frameworks/base grep -rl '@TestApi' --include '*.java' | xargs perl -i -p0e \ 's/\@SystemApi[\s\n]+(\@\w+[\s\n]+)?\@TestApi/\@SystemApi\1/gs' grep -rl '@TestApi' --include '*.java' | xargs perl -i -p0e \ 's/\@TestApi[\s\n]+(\@\w+[\s\n]+)?\@SystemApi/\1\@SystemApi/gs' Bug: 171179806 Test: m checkapi Change-Id: I772790b783b0a8730b8bf680c9e569a886b8d789 Merged-In: I772790b783b0a8730b8bf680c9e569a886b8d789
* Merge "Fix ApfCapabilities, LinkAddress, RouteInfo, IpPrefix API issues." ↵Paul Hu2019-04-011-9/+11
|\ | | | | | | | | | | | | | | am: f9d61f1c6d am: 96f34c3151 am: bf3e6f5e75 Change-Id: I599dcdb2312a3e1bb1de8e03f349df207c7cc075
| * Fix ApfCapabilities, LinkAddress, RouteInfo, IpPrefix API issues.paulhu2019-04-011-9/+11
| | | | | | | | | | | | | | | | | | Fix: 129362082 Fix: 129361362 Fix: 129360330 Fix: 129362379 Test: atest FrameworksNetTests NetworkStackTests Change-Id: I05fbc6f98207d5cf002e3cbc5829040af7d6be52
* | Merge "Fix Automated API Review issues." am: 43c1ade661 am: 9e3f29037bPaul Hu2019-03-211-3/+4
|\| | | | | | | | | | | am: ce18c5a1ec Change-Id: Iba1630161579571d4975aba9bbd5c767f82c8a98
| * Fix Automated API Review issues.paulhu2019-03-211-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1. Some API's argument/return value must be marked either @NonNull or @Nullable. 2. Change some system APIs to public APIs. 3. Modify the method name Bug: 126700123 Bug: 126702339 Bug: 126699682 Bug: 118296575 Bug: 126699216 Bug: 126699675 Bug: 126699429 Bug: 126699193 Bug: 123586045 Test: atest FrameworksNetTests Change-Id: Iaa2832cdcf83758ed0fec81b954a0c63bc5a7bf6
* | All Parcelable CREATOR fields are @NonNull.Jeff Sharkey2019-02-281-1/+1
|/ | | | | | | | | If they were null, then the Parcelable would fail to work. Bug: 126726802 Test: manual Change-Id: I7929ffa2f20e5de1c8e68e8263cca99496e9d014 Exempt-From-Owner-Approval: Trivial API annotations
* Add NetworkUtils utilities to SystemApiRemi NGUYEN VAN2019-01-291-0/+2
| | | | | | | | | | | | attach*Filter and addArpEntry are necessary for the NetworkStack but are only usable for apps that have system permissions. Also includes system API for IpPrefix, LinkAddress, LinkProperties, Network, and static modifier in ApfCapabilities that were missed in previous CLs. Test: Builds, flashed, WiFi works Bug: 112869080 Change-Id: If141ae6a2f9145f5af64ba002ca44938f39b90a9
* Add additional SystemApi for NetworkStackRemi NGUYEN VAN2019-01-241-0/+4
| | | | | | | | | Members in this CL were missed in earlier changes. Test: m Bug: 112869080 Merged-In: I8b5b80ea7b267357eb0387d504a2f78358d6d502 Change-Id: I8b9b15f8b91962f3ef554fd222a825e471806c9e
* Give VPNs the INTERNET capability when they route most of the IP spaceChalard Jean2018-03-021-0/+47
| | | | | | Test: manual, plus wrote some new tests for this Bug: 72765718 Change-Id: I9759da72b752fd8eeb1d0647db9ab341f04c0528
* Add convenience methods to IpPrefix and LinkAddressHugo Benichi2017-08-161-0/+16
| | | | | | | | | | | | | | | | | | | | Also moving relevant test files into tests/net as part of runtest framworks-net. Also removes testHashCode in LinkAddress() because this test relies on the assumption that hashCode() is stable across releases or jdk versions, which is absolutely not true. This creates maintenance work for little benefit since hashCode is already tested as part of the equality test. For instance this test is now broken because hashing for InetAddress changed. Bug: 62988545 Bug: 62918393 Test: runtest frameworks-net, added coverage in tests Change-Id: I695bc3f0e801bf13bc4fc0706565758f12b775b4
* Add android.net.IpPrefix#contains()Erik Kline2015-04-141-0/+15
| | | | | | | | | This was originally to avoid RuntimeException in RouteInfo#matches(): When an IPv6 prefix with a length greater than the max permitted for IPv4 is matched against an Inet4Address, the call to NetworkUtils throws RuntimeException. Change-Id: I92e2bd19a4e7d656cf682fd27678da07e211850d
* Support non-unicast route types: unreachable and throw.Lorenzo Colitti2014-09-221-1/+1
| | | | | Bug: 17462989 Change-Id: I8635472ca3e96ec2866af2de48e6260ab2da13fb
* IpPrefix improvements.Lorenzo Colitti2014-06-171-12/+58
| | | | | | | | | | | | | | 1. Allow IpPrefixes to be created from strings. In order to do this, factor out the code from LinkAddress which already does this to a small utility class in NetworkUtils. 2. Truncate prefixes on creation, fixing a TODO. 3. Add a toString method. 4. Write a unit test. While I'm at it, make RouteInfoTest pass again, and convert it to use IpPrefix instead of LinkAddress. Change-Id: I5f68f8af8f4aedb25afaee00e05369f01e82a70b
* Make IpPrefix final.Robert Greenwalt2014-06-121-4/+1
| | | | | | Couldn't resolve a merge conflict, so skipped and make the change this way. Change-Id: Ib043f660fca2090f0d12a5a707e5e1ad28f76adb
* Add a new IpPrefix class and use it in RouteInfo.Sreeram Ramachandran2014-06-101-0/+173
This change uses IpPrefix only in the public API and continues to use LinkAddress for everything else. It does not change the callers to use the new APIs, with the exception of changing all current uses of getDestination to getDestinationLinkAddress to make room for the new getDestination method that returns an IpPrefix. Based on Sreeram's earlier change: https://googleplex-android-review.git.corp.google.com/#/c/477874/ but a bit simplified and with a bit more documentation. Bug: 15142362 Bug: 13885501 Change-Id: Ib4cd96b22cbff4ea31bb26a7853989f50da8de4e