diff options
author | Todd Poynor <toddpoynor@google.com> | 2013-12-10 11:57:21 -0800 |
---|---|---|
committer | Todd Poynor <toddpoynor@google.com> | 2014-04-15 13:54:08 -0700 |
commit | e35872da97ac6bd07d2d9ac5af8a7c18ad290718 (patch) | |
tree | 04d9a4d952290afef77939aa08fc0b7d9af330d5 /api | |
parent | 771cd657acc37b50bafe18bf5f649d3c1d85b3d8 (diff) | |
download | frameworks_base-e35872da97ac6bd07d2d9ac5af8a7c18ad290718.zip frameworks_base-e35872da97ac6bd07d2d9ac5af8a7c18ad290718.tar.gz frameworks_base-e35872da97ac6bd07d2d9ac5af8a7c18ad290718.tar.bz2 |
BatteryManager: Add API and service for battery property retrieval
Add service "batterymanager" and method getProperty to retrieve
battery properties. This is a public API.
Make BatteryProperty public. Cleanups for public-facing API.
Change-Id: I3637d131aabe4811dff40661728d5353eaf854c4
Diffstat (limited to 'api')
-rw-r--r-- | api/current.txt | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/api/current.txt b/api/current.txt index 2274ea0..c718881 100644 --- a/api/current.txt +++ b/api/current.txt @@ -6464,6 +6464,7 @@ package android.content { field public static final java.lang.String ALARM_SERVICE = "alarm"; field public static final java.lang.String APP_OPS_SERVICE = "appops"; field public static final java.lang.String AUDIO_SERVICE = "audio"; + field public static final java.lang.String BATTERY_SERVICE = "batterymanager"; field public static final int BIND_ABOVE_CLIENT = 8; // 0x8 field public static final int BIND_ADJUST_WITH_ACTIVITY = 128; // 0x80 field public static final int BIND_ALLOW_OOM_MANAGEMENT = 16; // 0x10 @@ -18974,6 +18975,7 @@ package android.os { public class BatteryManager { ctor public BatteryManager(); + method public android.os.BatteryProperty getProperty(int) throws android.os.RemoteException; field public static final int BATTERY_HEALTH_COLD = 7; // 0x7 field public static final int BATTERY_HEALTH_DEAD = 4; // 0x4 field public static final int BATTERY_HEALTH_GOOD = 2; // 0x2 @@ -19001,6 +19003,18 @@ package android.os { field public static final java.lang.String EXTRA_VOLTAGE = "voltage"; } + public class BatteryProperty implements android.os.Parcelable { + method public int describeContents(); + method public int getInt(); + method public void readFromParcel(android.os.Parcel); + method public void writeToParcel(android.os.Parcel, int); + field public static final int CAPACITY = 4; // 0x4 + field public static final int CHARGE_COUNTER = 1; // 0x1 + field public static final android.os.Parcelable.Creator CREATOR; + field public static final int CURRENT_AVERAGE = 3; // 0x3 + field public static final int CURRENT_NOW = 2; // 0x2 + } + public class Binder implements android.os.IBinder { ctor public Binder(); method public void attachInterface(android.os.IInterface, java.lang.String); |