1 /*
2  * Copyright (C) 2019 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 package android.app.timezonedetector;
18 
19 import android.app.time.ITimeZoneDetectorListener;
20 import android.app.time.TimeZoneCapabilitiesAndConfig;
21 import android.app.time.TimeZoneConfiguration;
22 import android.app.timezonedetector.ManualTimeZoneSuggestion;
23 import android.app.timezonedetector.TelephonyTimeZoneSuggestion;
24 
25 /**
26  * System private API to communicate with time zone detector service.
27  *
28  * <p>Used to provide information to the Time Zone Detector Service from other parts of the Android
29  * system that have access to time zone-related signals, e.g. telephony.
30  *
31  * <p>Use the {@link android.app.timezonedetector.TimeZoneDetector} class rather than going through
32  * this Binder interface directly. See {@link android.app.timezonedetector.TimeZoneDetectorService}
33  * for more complete documentation.
34  *
35  * {@hide}
36  */
37 interface ITimeZoneDetectorService {
getCapabilitiesAndConfig()38   TimeZoneCapabilitiesAndConfig getCapabilitiesAndConfig();
addListener(ITimeZoneDetectorListener listener)39   void addListener(ITimeZoneDetectorListener listener);
removeListener(ITimeZoneDetectorListener listener)40   void removeListener(ITimeZoneDetectorListener listener);
41 
updateConfiguration(in TimeZoneConfiguration configuration)42   boolean updateConfiguration(in TimeZoneConfiguration configuration);
43 
suggestManualTimeZone(in ManualTimeZoneSuggestion timeZoneSuggestion)44   boolean suggestManualTimeZone(in ManualTimeZoneSuggestion timeZoneSuggestion);
suggestTelephonyTimeZone(in TelephonyTimeZoneSuggestion timeZoneSuggestion)45   void suggestTelephonyTimeZone(in TelephonyTimeZoneSuggestion timeZoneSuggestion);
46 }
47