diff options
author | destradaa <destradaa@google.com> | 2014-08-15 11:33:57 -0700 |
---|---|---|
committer | destradaa <destradaa@google.com> | 2014-08-18 10:22:23 -0700 |
commit | c4e1e59561884afc2c71b4b52697f62bd6b38f99 (patch) | |
tree | 8739c5b7f5b7a2c509dbaaecc29641188e3932fe | |
parent | f6040e9c116e8723b3312499987c370d2e9ee7c7 (diff) | |
download | frameworks_base-c4e1e59561884afc2c71b4b52697f62bd6b38f99.zip frameworks_base-c4e1e59561884afc2c71b4b52697f62bd6b38f99.tar.gz frameworks_base-c4e1e59561884afc2c71b4b52697f62bd6b38f99.tar.bz2 |
Add @SystemApi annotation to Geofence Hardware types.
b/17008446
Change-Id: Id3f92dd03309324d3343c87da8c3e30733d06a64
6 files changed, 22 insertions, 83 deletions
diff --git a/api/current.txt b/api/current.txt index bdeae78..88ab6c4 100644 --- a/api/current.txt +++ b/api/current.txt @@ -13305,85 +13305,6 @@ package android.hardware.input { } -package android.hardware.location { - - public final class GeofenceHardware { - method public boolean addGeofence(int, int, android.hardware.location.GeofenceHardwareRequest, android.hardware.location.GeofenceHardwareCallback); - method public int[] getMonitoringTypes(); - method public int getStatusOfMonitoringType(int); - method public boolean pauseGeofence(int, int); - method public boolean registerForMonitorStateChangeCallback(int, android.hardware.location.GeofenceHardwareMonitorCallback); - method public boolean removeGeofence(int, int); - method public boolean resumeGeofence(int, int, int); - method public boolean unregisterForMonitorStateChangeCallback(int, android.hardware.location.GeofenceHardwareMonitorCallback); - field public static final int GEOFENCE_ENTERED = 1; // 0x1 - field public static final int GEOFENCE_ERROR_ID_EXISTS = 2; // 0x2 - field public static final int GEOFENCE_ERROR_ID_UNKNOWN = 3; // 0x3 - field public static final int GEOFENCE_ERROR_INSUFFICIENT_MEMORY = 6; // 0x6 - field public static final int GEOFENCE_ERROR_INVALID_TRANSITION = 4; // 0x4 - field public static final int GEOFENCE_ERROR_TOO_MANY_GEOFENCES = 1; // 0x1 - field public static final int GEOFENCE_EXITED = 2; // 0x2 - field public static final int GEOFENCE_FAILURE = 5; // 0x5 - field public static final int GEOFENCE_SUCCESS = 0; // 0x0 - field public static final int GEOFENCE_UNCERTAIN = 4; // 0x4 - field public static final int MONITORING_TYPE_FUSED_HARDWARE = 1; // 0x1 - field public static final int MONITORING_TYPE_GPS_HARDWARE = 0; // 0x0 - field public static final int MONITOR_CURRENTLY_AVAILABLE = 0; // 0x0 - field public static final int MONITOR_CURRENTLY_UNAVAILABLE = 1; // 0x1 - field public static final int MONITOR_UNSUPPORTED = 2; // 0x2 - field public static final int SOURCE_TECHNOLOGY_BLUETOOTH = 16; // 0x10 - field public static final int SOURCE_TECHNOLOGY_CELL = 8; // 0x8 - field public static final int SOURCE_TECHNOLOGY_GNSS = 1; // 0x1 - field public static final int SOURCE_TECHNOLOGY_SENSORS = 4; // 0x4 - field public static final int SOURCE_TECHNOLOGY_WIFI = 2; // 0x2 - } - - public abstract class GeofenceHardwareCallback { - ctor public GeofenceHardwareCallback(); - method public void onGeofenceAdd(int, int); - method public void onGeofencePause(int, int); - method public void onGeofenceRemove(int, int); - method public void onGeofenceResume(int, int); - method public void onGeofenceTransition(int, int, android.location.Location, long, int); - } - - public abstract class GeofenceHardwareMonitorCallback { - ctor public GeofenceHardwareMonitorCallback(); - method public deprecated void onMonitoringSystemChange(int, boolean, android.location.Location); - method public void onMonitoringSystemChange(android.hardware.location.GeofenceHardwareMonitorEvent); - } - - public class GeofenceHardwareMonitorEvent implements android.os.Parcelable { - ctor public GeofenceHardwareMonitorEvent(int, int, int, android.location.Location); - method public int describeContents(); - method public android.location.Location getLocation(); - method public int getMonitoringStatus(); - method public int getMonitoringType(); - method public int getSourceTechnologies(); - method public void writeToParcel(android.os.Parcel, int); - field public static final android.os.Parcelable.Creator CREATOR; - } - - public final class GeofenceHardwareRequest { - ctor public GeofenceHardwareRequest(); - method public static android.hardware.location.GeofenceHardwareRequest createCircularGeofence(double, double, double); - method public int getLastTransition(); - method public double getLatitude(); - method public double getLongitude(); - method public int getMonitorTransitions(); - method public int getNotificationResponsiveness(); - method public double getRadius(); - method public int getSourceTechnologies(); - method public int getUnknownTimer(); - method public void setLastTransition(int); - method public void setMonitorTransitions(int); - method public void setNotificationResponsiveness(int); - method public void setSourceTechnologies(int); - method public void setUnknownTimer(int); - } - -} - package android.hardware.usb { public class UsbAccessory implements android.os.Parcelable { diff --git a/core/java/android/hardware/location/GeofenceHardware.java b/core/java/android/hardware/location/GeofenceHardware.java index 2d82cba..7dd105a 100644 --- a/core/java/android/hardware/location/GeofenceHardware.java +++ b/core/java/android/hardware/location/GeofenceHardware.java @@ -15,6 +15,7 @@ */ package android.hardware.location; +import android.annotation.SystemApi; import android.location.Location; import android.os.Build; import android.os.RemoteException; @@ -43,7 +44,10 @@ import java.util.HashMap; * an appropriate transition would be triggered. The "reasonably confident" parameter * depends on the hardware system and the positioning algorithms used. * For instance, {@link #MONITORING_TYPE_GPS_HARDWARE} uses 95% as a confidence level. + * + * @hide */ +@SystemApi public final class GeofenceHardware { private IGeofenceHardware mService; @@ -162,9 +166,7 @@ public final class GeofenceHardware { private HashMap<GeofenceHardwareMonitorCallback, GeofenceHardwareMonitorCallbackWrapper> mMonitorCallbacks = new HashMap<GeofenceHardwareMonitorCallback, GeofenceHardwareMonitorCallbackWrapper>(); - /** - * @hide - */ + public GeofenceHardware(IGeofenceHardware service) { mService = service; } diff --git a/core/java/android/hardware/location/GeofenceHardwareCallback.java b/core/java/android/hardware/location/GeofenceHardwareCallback.java index 6cad3da..a2a7ed0 100644 --- a/core/java/android/hardware/location/GeofenceHardwareCallback.java +++ b/core/java/android/hardware/location/GeofenceHardwareCallback.java @@ -16,11 +16,15 @@ package android.hardware.location; +import android.annotation.SystemApi; import android.location.Location; /** * The callback class associated with the APIs in {@link GeofenceHardware} + * + * @hide */ +@SystemApi public abstract class GeofenceHardwareCallback { /** * The callback called when there is a transition to report for the specific diff --git a/core/java/android/hardware/location/GeofenceHardwareMonitorCallback.java b/core/java/android/hardware/location/GeofenceHardwareMonitorCallback.java index f927027..d7daa10 100644 --- a/core/java/android/hardware/location/GeofenceHardwareMonitorCallback.java +++ b/core/java/android/hardware/location/GeofenceHardwareMonitorCallback.java @@ -16,12 +16,16 @@ package android.hardware.location; +import android.annotation.SystemApi; import android.location.Location; /** * The callback class associated with the status change of hardware monitors * in {@link GeofenceHardware} + * + * @hide */ +@SystemApi public abstract class GeofenceHardwareMonitorCallback { /** * The callback called when the state of a monitoring system changes. diff --git a/core/java/android/hardware/location/GeofenceHardwareMonitorEvent.java b/core/java/android/hardware/location/GeofenceHardwareMonitorEvent.java index 9c460d2..7079237 100644 --- a/core/java/android/hardware/location/GeofenceHardwareMonitorEvent.java +++ b/core/java/android/hardware/location/GeofenceHardwareMonitorEvent.java @@ -16,13 +16,17 @@ package android.hardware.location; +import android.annotation.SystemApi; import android.location.Location; import android.os.Parcel; import android.os.Parcelable; /** * A class that represents an event for each change in the state of a monitoring system. + * + * @hide */ +@SystemApi public class GeofenceHardwareMonitorEvent implements Parcelable { private final int mMonitoringType; private final int mMonitoringStatus; diff --git a/core/java/android/hardware/location/GeofenceHardwareRequest.java b/core/java/android/hardware/location/GeofenceHardwareRequest.java index 887c4ad..68545a8 100644 --- a/core/java/android/hardware/location/GeofenceHardwareRequest.java +++ b/core/java/android/hardware/location/GeofenceHardwareRequest.java @@ -16,12 +16,16 @@ package android.hardware.location; +import android.annotation.SystemApi; + /** * This class represents the characteristics of the geofence. * * <p> Use this in conjunction with {@link GeofenceHardware} APIs. + * + * @hide */ - +@SystemApi public final class GeofenceHardwareRequest { static final int GEOFENCE_TYPE_CIRCLE = 0; private int mType; |