android.content.ContentQueryMap
Caches the contents of a cursor into a Map of String->ContentValues and optionally
keeps the cache fresh by registering for updates on the cursor. The column of the
database that is to be used as the key of the map is user-configurable, and the
ContentValues contains all columns other than the one that is designated the key.
The cursor data is accessed by row key and column name via getValue().
Summary
Public Constructors
Public Methods
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait
Details
Public Constructors
public
ContentQueryMap(Cursor cursor, String columnNameOfKey, boolean keepUpdated, Handler handlerForUpdateNotifications)
Creates a ContentQueryMap that caches the contents of the cursor.
Parameters
| cursor
| the cursor whose contents should be cached |
| columnNameOfKey
| the column that is to be used as the key of the values map |
| keepUpdated
| true if the cursor should be monitored for changes and the
map updated when changes do occur |
| handlerForUpdateNotifications
| the Handler that should be used to receive
notifications of changes (if requested). Normally you pass null here, but if
you know that the thread that is creating this isn't a thread that can receive
messages then you can create your own handler and use that here.
|
Public Methods
Access the ContentValues for the row specified by rowName
Parameters
| rowName
| which row to read |
Returns
- the ContentValues for the row, or null if the row wasn't present in the cursor
public
void
requery()
Requeries the cursor and reads the contents into mValues