|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
A listener interface for receiving and reacting to low memory events.
LowMemoryFailedListener,
LowMemoryManager| Field Summary | ||
|
static int |
HIGH_PRIORITY
The highest priority of low memory requests. |
|
static int |
LOW_PRIORITY
The lowest priority of low memory requests. |
|
static int |
MEDIUM_PRIORITY
The middle priority of low memory requests. |
| Method Summary | ||
|
boolean |
freeStaleObject(int priority)
Called when the amount of available flash on the device has dropped below a safe level. |
| Field Detail |
public static final int LOW_PRIORITY
In response to requests at LOW_PRIORITY, the listener should only free non-critical objects such as cached data.
public static final int MEDIUM_PRIORITY
In response to requests at MEDIUM_PRIORITY, the listener should free objects that are "stale" such as very old unfiled messages or old calendar entries.
public static final int HIGH_PRIORITY
In response to requests at HIGH_PRIORITY, the listener should free any objects that it considers to be "stale" in an effort to meet the memory requirements.
| Method Detail |
public boolean freeStaleObject(int priority)
In response to this call, the listener should
attempt to free one stale persistent object, and call
LowMemoryManager.markAsRecoverable(Object o) to indicate to the VM the
amount of flash freed.
priority - The priority level of the request. Listeners should use
parameter to determine what types of objects are to be freed.true if some persistent object was released;
false otherwise.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
Copyright 1999-2002 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Copyright 1993-2000 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, California, 94303, U.S.A. All Rights Reserved.
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.