summaryrefslogtreecommitdiff
path: root/location/java
diff options
context:
space:
mode:
Diffstat (limited to 'location/java')
-rw-r--r--location/java/android/location/altitude/AltitudeConverter.java12
-rw-r--r--location/java/android/location/flags/location.aconfig7
2 files changed, 14 insertions, 5 deletions
diff --git a/location/java/android/location/altitude/AltitudeConverter.java b/location/java/android/location/altitude/AltitudeConverter.java
index 6f8891216bed..461dafb91916 100644
--- a/location/java/android/location/altitude/AltitudeConverter.java
+++ b/location/java/android/location/altitude/AltitudeConverter.java
@@ -16,12 +16,14 @@
package android.location.altitude;
+import android.annotation.FlaggedApi;
import android.annotation.NonNull;
import android.annotation.WorkerThread;
import android.content.Context;
import android.frameworks.location.altitude.GetGeoidHeightRequest;
import android.frameworks.location.altitude.GetGeoidHeightResponse;
import android.location.Location;
+import android.location.flags.Flags;
import com.android.internal.location.altitude.GeoidMap;
import com.android.internal.location.altitude.S2CellIdUtils;
@@ -213,12 +215,12 @@ public final class AltitudeConverter {
}
/**
- * Same as {@link #addMslAltitudeToLocation(Context, Location)} except that data will not be
- * loaded from raw assets. Returns true if a Mean Sea Level altitude is added to the
- * {@code location}; otherwise, returns false and leaves the {@code location} unchanged.
- *
- * @hide
+ * Same as {@link #addMslAltitudeToLocation(Context, Location)} except that this method can be
+ * called on the main thread as data will not be loaded from raw assets. Returns true if a Mean
+ * Sea Level altitude is added to the {@code location}; otherwise, returns false and leaves the
+ * {@code location} unchanged.
*/
+ @FlaggedApi(Flags.FLAG_GEOID_HEIGHTS_VIA_ALTITUDE_HAL)
public boolean addMslAltitudeToLocation(@NonNull Location location) {
validate(location);
MapParamsProto geoidHeightParams = GeoidMap.getGeoidHeightParams();
diff --git a/location/java/android/location/flags/location.aconfig b/location/java/android/location/flags/location.aconfig
index 32ad09c00d37..a96fe47f2381 100644
--- a/location/java/android/location/flags/location.aconfig
+++ b/location/java/android/location/flags/location.aconfig
@@ -8,6 +8,13 @@ flag {
}
flag {
+ name: "geoid_heights_via_altitude_hal"
+ namespace: "location"
+ description: "Flag for making geoid heights available via the Altitude HAL"
+ bug: "304375846"
+}
+
+flag {
name: "gnss_api_navic_l1"
namespace: "location"
description: "Flag for GNSS API for NavIC L1"