| java.lang.Object | |||
| android.widget.BaseAdapter | Adapter GalleryAdapter ListAdapter | ||
| android.widget.CursorAdapter | Filterable | ||
Adapter that exposes data from a Cursor to a ListView widget. The Cursor must include a column named "_id" or this class will not work.
Known Direct Subclasses
Known Indirect Subclasses
Constants inherited
from interface
android.widget.Adapter
| protected | boolean | mAutoRequery | |||
| protected | ChangeObserver | mChangeObserver | |||
| protected | Context | mContext | |||
| protected | Cursor | mCursor | |||
| protected | DataSetObserver | mDataSetObserver | |||
| protected | boolean | mDataValid | |||
| protected | int | mRowIDColumn |
| CursorAdapter(Cursor c, Context context) | |||||
| Constructor. | |||||
| CursorAdapter(Cursor c, Context context, boolean autoRequery) | |||||
| Constructor | |||||
| abstract | void | bindView(View view, Context context, Cursor cursor) | |||
| Bind an existing view to the data pointed to by cursor | |||||
| void | changeCursor(Cursor cursor) | ||||
| Change the underlying cursor to a new cursor | |||||
| float | getAlpha(boolean focused, int offset) | ||||
Return the translucency of the specified item in the gallery. |
|||||
| final | int | getCount() | |||
| Cursor | getCursor() | ||||
| Returns the cursor. | |||||
| View | getDropDownView(int position, View convertView, ViewGroup parent) | ||||
Get a View that displays in the drop down popup the data at the specified position in the data set. |
|||||
| Filter | getFilter() | ||||
Returns a filter that can be used to constrain data with a filtering pattern. |
|||||
| final | Object | getItem(int position) | |||
| final | long | getItemId(int position) | |||
| float | getScale(boolean focused, int offset) | ||||
Return the scale factor of the specified item in the gallery. |
|||||
| View | getView(int position, View convertView, ViewGroup parent) | ||||
| View | newDropDownView(Context context, Cursor cursor, ViewGroup parent) | ||||
| Makes a new drop down view to hold the data pointed to by cursor. | |||||
| abstract | View | newView(Context context, Cursor cursor, ViewGroup parent) | |||
| Makes a new view to hold the data pointed to by cursor. | |||||
| boolean | stableIds() | ||||
| Indicated whether the item ids are stable across changes to the underlying data. | |||||
| String | convertToString(Cursor cursor) | ||||
Converts the cursor into a String. |
|||||
| void | init(Cursor c, Context context, boolean autoRequery) | ||||
| Cursor | runQuery(CharSequence constraint) | ||||
Runs a query with the specified constraint. |
|||||
Methods inherited
from class
android.widget.BaseAdapter
Methods inherited
from class
java.lang.Object
Methods inherited
from interface
android.widget.GalleryAdapter
Methods inherited
from interface
android.widget.ListAdapter
Methods inherited
from interface
android.widget.Filterable
Methods inherited
from interface
android.widget.SpinnerAdapter
Methods inherited
from interface
android.widget.Adapter
| c | The cursor from which to get the data. |
|---|---|
| context | The context |
| c | The cursor from which to get the data. |
|---|---|
| context | The context |
| autoRequery | If true the adapter will call requery() on the cursor whenever it changes so the most recent data is always displayed. |
| view | Existing view, returned earlier by newView |
|---|---|
| context | Interface to application's global information |
| cursor | The cursor from which to get the data. The cursor is already moved to the correct position. |
| cursor | the new cursor to be used |
|---|
Return the translucency of the specified item in the gallery.
Get a View that displays in the drop down popup the data at the specified position in the data set.
Returns a filter that can be used to constrain data with a filtering pattern.
This method is usually implemented by Adapter classes.
Return the scale factor of the specified item in the gallery.
| context | Interface to application's global information |
|---|---|
| cursor | The cursor from which to get the data. The cursor is already moved to the correct position. |
| parent | The parent to which the new view is attached to |
| context | Interface to application's global information |
|---|---|
| cursor | The cursor from which to get the data. The cursor is already moved to the correct position. |
| parent | The parent to which the new view is attached to |
Converts the cursor into a String. Subclasses should override this method to convert their results. The default implementation returns an empty String for null values or the default String representation of the value.
| cursor | the cursor to convert to a String |
|---|
Runs a query with the specified constraint. This query is requested by the filter attached to this adapter. The default implementation does not run any query and returns the current cursor. Subclasses should override this method to filter their results.
Contract: when constraint is null or empty, the original results, prior to any filtering, must be returned.
| constraint | the constraint with which the query must be filtered |
|---|