Make NET_CAPABILITY_VALIDATED (almost) a first-class citizen.
1. Always keep ConnectivityService's validated bits current:
- Apply the validated bit whenever a NetworkAgent updates its
NetworkCapabilities.
- Set or clear the validated bit whenever lastValidated changes.
2. Send callbacks when the validation state of a network changes.
3. Delete getNetworkCapabilitiesAndValidation, removing code
duplication with getNetworkCapabilities.
4. Add the validated bit to NetworkCapabilities#toString.
Bug: 18591282
Bug: 20081183
Change-Id: I6aa53b61c15cc137f203f9fc6bbd4c16894be750
2 files changed