Add a configuration retrieval manager.
The CarConfigurationManager is currently only returning the
configuration for speed bump, which is hard-coded.
Change-Id: I1862340ff40f8c61ec64c5eff8a0899f7f672391
Fixes: 71817274
Fixes: 70338684
Fixes: 71817172
Test: Write unit test and run the test
diff --git a/car-lib/api/current.txt b/car-lib/api/current.txt
index 68f8bc9..81b754e 100644
--- a/car-lib/api/current.txt
+++ b/car-lib/api/current.txt
@@ -11,6 +11,7 @@
method public boolean isConnecting();
field public static final java.lang.String APP_FOCUS_SERVICE = "app_focus";
field public static final java.lang.String AUDIO_SERVICE = "audio";
+ field public static final java.lang.String CAR_CONFIGURATION_SERVICE = "configuration";
field public static final java.lang.String CAR_EXTRA_MEDIA_PACKAGE = "android.car.intent.extra.MEDIA_PACKAGE";
field public static final java.lang.String CAR_INTENT_ACTION_MEDIA_TEMPLATE = "android.car.intent.action.MEDIA_TEMPLATE";
field public static final java.lang.String CAR_UX_RESTRICTION_SERVICE = "uxrestriction";
@@ -362,6 +363,10 @@
package android.car.settings {
+ public class CarConfigurationManager {
+ method public android.car.settings.SpeedBumpConfiguration getSpeedBumpConfiguration() throws android.car.CarNotConnectedException;
+ }
+
public class CarSettings {
ctor public CarSettings();
}
@@ -373,5 +378,15 @@
field public static final java.lang.String KEY_GARAGE_MODE_WAKE_UP_TIME = "android.car.GARAGE_MODE_WAKE_UP_TIME";
}
+ public final class SpeedBumpConfiguration implements android.os.Parcelable {
+ ctor public SpeedBumpConfiguration(double, double, long);
+ method public int describeContents();
+ method public double getAcquiredPermitsPerSecond();
+ method public double getMaxPermitPool();
+ method public long getPermitFillDelay();
+ method public void writeToParcel(android.os.Parcel, int);
+ field public static final android.os.Parcelable.Creator<android.car.settings.SpeedBumpConfiguration> CREATOR;
+ }
+
}