Stay organized with collections
Save and categorize content based on your preferences.
EvChargeState
public
final
class
EvChargeState
extends Object
java.lang.Object
|
↳ |
android.car.hardware.property.EvChargeState
|
Possible EV charge states of a vehicle.
Applications can use CarPropertyManager.getProperty(int, int)
with VehiclePropertyIds.EV_CHARGE_STATE
to query the vehicle's ignition
charge state.
Summary
Public methods |
static
String
|
toString(int evChargeState)
Gets a user-friendly representation of an EV charge state.
|
Inherited methods |
From class
java.lang.Object
Object
|
clone()
|
boolean
|
equals(Object arg0)
|
void
|
finalize()
|
final
Class<?>
|
getClass()
|
int
|
hashCode()
|
final
void
|
notify()
|
final
void
|
notifyAll()
|
String
|
toString()
|
final
void
|
wait(long arg0, int arg1)
|
final
void
|
wait(long arg0)
|
final
void
|
wait()
|
|
Constants
STATE_CHARGING
public static final int STATE_CHARGING
The vehicle is charging.
Constant Value:
1
(0x00000001)
STATE_ERROR
public static final int STATE_ERROR
The vehicle is not charging due to an error.
Constant Value:
4
(0x00000004)
STATE_FULLY_CHARGED
public static final int STATE_FULLY_CHARGED
The vehicle is fully charged.
Constant Value:
2
(0x00000002)
STATE_NOT_CHARGING
public static final int STATE_NOT_CHARGING
The vehicle is not charging.
Constant Value:
3
(0x00000003)
STATE_UNKNOWN
public static final int STATE_UNKNOWN
The vehicle's EV charge state is unknown.
Constant Value:
0
(0x00000000)
Public methods
toString
public static String toString (int evChargeState)
Gets a user-friendly representation of an EV charge state.
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-02-17 UTC.
[null,null,["Last updated 2025-02-17 UTC."],[],[],null,["# EvChargeState\n\nSummary: [Constants](#constants) \\| [Methods](#pubmethods) \\| [Inherited Methods](#inhmethods) \n\nEvChargeState\n=============\n\n\n`\npublic\n\nfinal\n\nclass\nEvChargeState\n`\n\n\n`\n\nextends Object\n\n\n`\n\n`\n\n\n`\n\n|---|---------------------------------------------|\n| java.lang.Object ||\n| ↳ | android.car.hardware.property.EvChargeState |\n\n\u003cbr /\u003e\n\n*** ** * ** ***\n\nPossible EV charge states of a vehicle.\n\nApplications can use [CarPropertyManager.getProperty(int, int)](/reference/android/car/hardware/property/CarPropertyManager#getProperty(int,%20int)) with [VehiclePropertyIds.EV_CHARGE_STATE](/reference/android/car/VehiclePropertyIds#EV_CHARGE_STATE) to query the vehicle's ignition\ncharge state.\n\nSummary\n-------\n\n| ### Constants ||\n|-------|---------------------------------------------------------------------------------------------------------------------------------|\n| `int` | [STATE_CHARGING](/reference/android/car/hardware/property/EvChargeState#STATE_CHARGING) The vehicle is charging. |\n| `int` | [STATE_ERROR](/reference/android/car/hardware/property/EvChargeState#STATE_ERROR) The vehicle is not charging due to an error. |\n| `int` | [STATE_FULLY_CHARGED](/reference/android/car/hardware/property/EvChargeState#STATE_FULLY_CHARGED) The vehicle is fully charged. |\n| `int` | [STATE_NOT_CHARGING](/reference/android/car/hardware/property/EvChargeState#STATE_NOT_CHARGING) The vehicle is not charging. |\n| `int` | [STATE_UNKNOWN](/reference/android/car/hardware/property/EvChargeState#STATE_UNKNOWN) The vehicle's EV charge state is unknown. |\n\n| ### Public methods ||\n|------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ` static String` | ` `[toString](/reference/android/car/hardware/property/EvChargeState#toString(int))`(int evChargeState) ` Gets a user-friendly representation of an EV charge state. |\n\n| ### Inherited methods |\n|-----------------------|---|\n| From class ` java.lang.Object ` |-------------------|-------------------------------| | ` Object` | ` clone() ` | | ` boolean` | ` equals(Object arg0) ` | | ` void` | ` finalize() ` | | ` final Class\u003c?\u003e` | ` getClass() ` | | ` int` | ` hashCode() ` | | ` final void` | ` notify() ` | | ` final void` | ` notifyAll() ` | | ` String` | ` toString() ` | | ` final void` | ` wait(long arg0, int arg1) ` | | ` final void` | ` wait(long arg0) ` | | ` final void` | ` wait() ` | ||\n\nConstants\n---------\n\n### STATE_CHARGING\n\n```\npublic static final int STATE_CHARGING\n```\n\nThe vehicle is charging.\n\n\u003cbr /\u003e\n\nConstant Value:\n\n1\n(0x00000001)\n\n\n### STATE_ERROR\n\n```\npublic static final int STATE_ERROR\n```\n\nThe vehicle is not charging due to an error.\n\n\u003cbr /\u003e\n\nConstant Value:\n\n4\n(0x00000004)\n\n\n### STATE_FULLY_CHARGED\n\n```\npublic static final int STATE_FULLY_CHARGED\n```\n\nThe vehicle is fully charged.\n\n\u003cbr /\u003e\n\nConstant Value:\n\n2\n(0x00000002)\n\n\n### STATE_NOT_CHARGING\n\n```\npublic static final int STATE_NOT_CHARGING\n```\n\nThe vehicle is not charging.\n\n\u003cbr /\u003e\n\nConstant Value:\n\n3\n(0x00000003)\n\n\n### STATE_UNKNOWN\n\n```\npublic static final int STATE_UNKNOWN\n```\n\nThe vehicle's EV charge state is unknown.\n\n\u003cbr /\u003e\n\nConstant Value:\n\n0\n(0x00000000)\n\n\nPublic methods\n--------------\n\n### toString\n\n```\npublic static String toString (int evChargeState)\n```\n\nGets a user-friendly representation of an EV charge state.\n\n\u003cbr /\u003e\n\n| Parameters ||\n|-----------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `evChargeState` | `int`: Value is [STATE_UNKNOWN](/reference/android/car/hardware/property/EvChargeState#STATE_UNKNOWN), [STATE_CHARGING](/reference/android/car/hardware/property/EvChargeState#STATE_CHARGING), [STATE_FULLY_CHARGED](/reference/android/car/hardware/property/EvChargeState#STATE_FULLY_CHARGED), [STATE_NOT_CHARGING](/reference/android/car/hardware/property/EvChargeState#STATE_NOT_CHARGING), or [STATE_ERROR](/reference/android/car/hardware/property/EvChargeState#STATE_ERROR) \u003cbr /\u003e |\n\n| Returns ||\n|----------|--------|\n| `String` | \u003cbr /\u003e |"]]