Merge "Tidy up module-lib API and locks"

This commit is contained in:
Neil Fuller
2020-01-29 14:10:18 +00:00
committed by Gerrit Code Review
7 changed files with 11 additions and 11 deletions

View File

@@ -102,18 +102,18 @@ package android.timezone {
method @NonNull public String getTimeZoneId(); method @NonNull public String getTimeZoneId();
} }
public class TelephonyLookup { public final class TelephonyLookup {
method @NonNull public static android.timezone.TelephonyLookup getInstance(); method @NonNull public static android.timezone.TelephonyLookup getInstance();
method @Nullable public android.timezone.TelephonyNetworkFinder getTelephonyNetworkFinder(); method @Nullable public android.timezone.TelephonyNetworkFinder getTelephonyNetworkFinder();
} }
public class TelephonyNetwork { public final class TelephonyNetwork {
method @NonNull public String getCountryIsoCode(); method @NonNull public String getCountryIsoCode();
method @NonNull public String getMcc(); method @NonNull public String getMcc();
method @NonNull public String getMnc(); method @NonNull public String getMnc();
} }
public class TelephonyNetworkFinder { public final class TelephonyNetworkFinder {
method @Nullable public android.timezone.TelephonyNetwork findNetworkByMccMnc(@NonNull String, @NonNull String); method @Nullable public android.timezone.TelephonyNetwork findNetworkByMccMnc(@NonNull String, @NonNull String);
} }
@@ -134,7 +134,7 @@ package android.timezone {
method @NonNull public static android.timezone.TzDataSetVersion read() throws java.io.IOException, android.timezone.TzDataSetVersion.TzDataSetException; method @NonNull public static android.timezone.TzDataSetVersion read() throws java.io.IOException, android.timezone.TzDataSetVersion.TzDataSetException;
} }
public static class TzDataSetVersion.TzDataSetException extends java.lang.Exception { public static final class TzDataSetVersion.TzDataSetException extends java.lang.Exception {
ctor public TzDataSetVersion.TzDataSetException(String); ctor public TzDataSetVersion.TzDataSetException(String);
ctor public TzDataSetVersion.TzDataSetException(String, Throwable); ctor public TzDataSetVersion.TzDataSetException(String, Throwable);
} }

View File

@@ -30,9 +30,9 @@ import java.util.Objects;
* @hide * @hide
*/ */
@SystemApi(client = SystemApi.Client.MODULE_LIBRARIES) @SystemApi(client = SystemApi.Client.MODULE_LIBRARIES)
public class TelephonyLookup { public final class TelephonyLookup {
private static Object sLock = new Object(); private static final Object sLock = new Object();
@GuardedBy("sLock") @GuardedBy("sLock")
private static TelephonyLookup sInstance; private static TelephonyLookup sInstance;

View File

@@ -27,7 +27,7 @@ import java.util.Objects;
* @hide * @hide
*/ */
@SystemApi(client = SystemApi.Client.MODULE_LIBRARIES) @SystemApi(client = SystemApi.Client.MODULE_LIBRARIES)
public class TelephonyNetwork { public final class TelephonyNetwork {
@NonNull @NonNull
private final libcore.timezone.TelephonyNetwork mDelegate; private final libcore.timezone.TelephonyNetwork mDelegate;

View File

@@ -28,7 +28,7 @@ import java.util.Objects;
* @hide * @hide
*/ */
@SystemApi(client = SystemApi.Client.MODULE_LIBRARIES) @SystemApi(client = SystemApi.Client.MODULE_LIBRARIES)
public class TelephonyNetworkFinder { public final class TelephonyNetworkFinder {
@NonNull @NonNull
private final libcore.timezone.TelephonyNetworkFinder mDelegate; private final libcore.timezone.TelephonyNetworkFinder mDelegate;

View File

@@ -32,7 +32,7 @@ import java.util.Objects;
@SystemApi(client = SystemApi.Client.MODULE_LIBRARIES) @SystemApi(client = SystemApi.Client.MODULE_LIBRARIES)
public final class TimeZoneFinder { public final class TimeZoneFinder {
private static Object sLock = new Object(); private static final Object sLock = new Object();
@GuardedBy("sLock") @GuardedBy("sLock")
private static TimeZoneFinder sInstance; private static TimeZoneFinder sInstance;

View File

@@ -89,7 +89,7 @@ public final class TzDataSetVersion {
* @hide * @hide
*/ */
@SystemApi(client = SystemApi.Client.MODULE_LIBRARIES) @SystemApi(client = SystemApi.Client.MODULE_LIBRARIES)
public static class TzDataSetException extends Exception { public static final class TzDataSetException extends Exception {
/** Creates an instance with a message. */ /** Creates an instance with a message. */
public TzDataSetException(String message) { public TzDataSetException(String message) {

View File

@@ -32,7 +32,7 @@ import java.util.Objects;
@SystemApi(client = SystemApi.Client.MODULE_LIBRARIES) @SystemApi(client = SystemApi.Client.MODULE_LIBRARIES)
public final class ZoneInfoDb { public final class ZoneInfoDb {
private static Object sLock = new Object(); private static final Object sLock = new Object();
@GuardedBy("sLock") @GuardedBy("sLock")
private static ZoneInfoDb sInstance; private static ZoneInfoDb sInstance;