|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--net.rim.device.api.system.DeviceInfo
This class provides access to fundamental information about the host device.
| Field Summary | ||
static int |
BSTAT_CHARGING
Battery is charging. |
|
static int |
BSTAT_DEAD
Battery at or below zero percent. |
|
static int |
BSTAT_IS_USING_EXTERNAL_POWER
Device is connected to an external power source. |
|
static int |
BSTAT_LEVEL_CHANGED
The level of the battery has changed, call getBatteryLevel() for detailed info on the Battery Level |
|
static int |
BSTAT_LOW
Battery is low. |
|
static int |
BSTAT_LOW_RATE_CHARGING
Battery is charging, but at a reduced rate. |
|
static int |
BSTAT_NO_RADIO
Battery is too low for radio usage. |
|
static int |
BSTAT_NO_TURN_ON
Battery is too low for device to turn on. |
|
static int |
BSTAT_NONE
No battery. |
|
static int |
BSTAT_REVERSED
Battery is inserted backwards. |
|
static int |
BSTAT_TOO_COLD
Battery is too cold. |
|
static int |
BSTAT_TOO_HOT
Battery is too hot. |
|
static int |
BSTAT_UNKNOWN_BATTERY
Battery is not recognized by the firmware. |
|
| Method Summary | ||
static int |
getBatteryLevel()
Retrieves the current battery level. |
|
static int |
getBatteryStatus()
Retrieves the battery status. |
|
static int |
getBatteryTemperature()
Retrieves battery's current temperature. |
|
static int |
getBatteryVoltage()
Retrieves battery's current voltage. |
|
static int |
getDeviceId()
Retrieves the PIN number for this device. |
|
static String |
getDeviceName()
Retrieves this device's product name. |
|
static long |
getIdleTime()
Retrieves the number of seconds since the last key or thumbwheel event. |
|
static String |
getManufacturerName()
Retrieve the device manufacturer's name. |
|
static int |
getOSVersion()
Deprecated. This function attempts to pack the String returned by getPlatformVersion() into the format specified above. If it is
unsuccessful, it will return 0. Please use getPlatformVersion() instead. |
|
static String |
getPlatformVersion()
Retrieves the platform version. |
|
static boolean |
isBatteryRemovable()
Determines if this device has a removable battery. |
|
static boolean |
isInHolster()
Determines if this device is in the holster. |
|
boolean |
isPasswordEnabled()
Check if the password is currently enabled on the device. |
|
static boolean |
isSimulator()
Determines if this device is really a simulator. |
|
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final int BSTAT_UNKNOWN_BATTERY
public static final int BSTAT_LOW_RATE_CHARGING
public static final int BSTAT_IS_USING_EXTERNAL_POWER
public static final int BSTAT_LEVEL_CHANGED
| Method Detail |
public static int getDeviceId()
This method will return the PIN number of a device or the default
value of 0x21000000a if connected to the simulator. You can
modify the default value associated with the simulator by using the
RSIM command line option.
The RSIM command line option takes the form of:
/RSIM=<PIN> where PIN is the integer value
to be associated with the simulator.
public static int getBatteryLevel()
public static int getBatteryStatus()
public static boolean isBatteryRemovable()
public static int getOSVersion()
getPlatformVersion() into the format specified above. If it is
unsuccessful, it will return 0. Please use getPlatformVersion() instead.
public static String getPlatformVersion()
public static boolean isInHolster()
public static long getIdleTime()
public static boolean isSimulator()
public static String getDeviceName()
public static int getBatteryVoltage()
public static int getBatteryTemperature()
public boolean isPasswordEnabled()
public static String getManufacturerName()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
Copyright 1999-2004 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Copyright 1993-2003 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, California, 94303, U.S.A.
Copyright 2002-2003 Nokia Corporation All Rights Reserved.
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.