diff options
author | Neil Fuller <nfuller@google.com> | 2020-02-24 16:19:48 +0000 |
---|---|---|
committer | Neil Fuller <nfuller@google.com> | 2020-06-15 11:18:46 +0100 |
commit | 7c7709207f136fecc15e46bcad3c72e259073c14 (patch) | |
tree | 5b16edc735d4e2aecc9b00ecfcb447c31804dcd0 /tools/aapt2/java/JavaClassGenerator_test.cpp | |
parent | 472e277ce60572b169f780baeba3a37f8c2a7cd4 (diff) |
Make TimeZoneDetector own its config
Make TimeZoneDetector responsible for configuration of time
zone detection behavior on device and have it enforce user capabilities.
This provides a set of configuration/capability classes, listeners and
tests that should allow SettingsUI apps to switch over to using them
while maintaining existing behavior and restrictions.
Ultimately, this should get us to a point where all time zone detection
configuration is conducted via TimeZoneDetector.updateConfiguration()
rather than modifying / listening to android.provider.Settings directly.
The listener support is intended for any users that currently watch
settings directly.
The TimeZoneCapabilities and TimeZoneConfiguration are designed to be
extensible so that more configuration properties can be added as the
time zone detector becomes more sophisticated. updateConfiguration()
supports partial configs so that clients only need to be explicit about
the config properties they know about and want to change.
This change is also a step towards removing race conditions in time zone
detection that could occur if settings are changed mid-way through a
time zone detection cycle: synchronization in
TimeZoneDetectorStrategyImpl ensures that the configuration won't change
unexpectedly.
Test: atest services/tests/servicestests/src/com/android/server/timezonedetector
Test: atest core/tests/coretests/src/android/app/timezonedetector
Change-Id: I3283b7fb7aa978df44a27ab7cd8cacdbe042b17b
Diffstat (limited to 'tools/aapt2/java/JavaClassGenerator_test.cpp')
0 files changed, 0 insertions, 0 deletions