|
Build 1.0_r1(from source) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectandroid.widget.Filter
android.widget.CursorFilter
class CursorFilter
The CursorFilter delegates most of the work to the CursorAdapter. Subclasses should override these delegate methods to run the queries and convert the results into String that can be used by auto-completion widgets.
| Nested Class Summary | |
|---|---|
(package private) static interface |
CursorFilter.CursorFilterClient
|
| Nested classes/interfaces inherited from class android.widget.Filter |
|---|
Filter.FilterListener, Filter.FilterResults |
| Field Summary | |
|---|---|
(package private) CursorFilter.CursorFilterClient |
mClient
|
| Constructor Summary | |
|---|---|
CursorFilter(CursorFilter.CursorFilterClient client)
|
|
| Method Summary | |
|---|---|
CharSequence |
convertResultToString(Object resultValue)
Converts a value from the filtered set into a CharSequence. |
protected Filter.FilterResults |
performFiltering(CharSequence constraint)
Invoked in a worker thread to filter the data according to the constraint. |
protected void |
publishResults(CharSequence constraint,
Filter.FilterResults results)
Invoked in the UI thread to publish the filtering results in the user interface. |
| Methods inherited from class android.widget.Filter |
|---|
filter, filter |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
CursorFilter.CursorFilterClient mClient
| Constructor Detail |
|---|
CursorFilter(CursorFilter.CursorFilterClient client)
| Method Detail |
|---|
public CharSequence convertResultToString(Object resultValue)
FilterConverts a value from the filtered set into a CharSequence. 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.
convertResultToString in class FilterresultValue - the value to convert to a CharSequence
protected Filter.FilterResults performFiltering(CharSequence constraint)
FilterInvoked in a worker thread to filter the data according to the
constraint. Subclasses must implement this method to perform the
filtering operation. Results computed by the filtering operation
must be returned as a Filter.FilterResults that
will then be published in the UI thread through
Filter.publishResults(CharSequence,
android.widget.Filter.FilterResults).
Contract: When the constraint is null, the original data must be restored.
performFiltering in class Filterconstraint - the constraint used to filter the data
Filter.filter(CharSequence, android.widget.Filter.FilterListener),
Filter.publishResults(CharSequence, android.widget.Filter.FilterResults),
Filter.FilterResults
protected void publishResults(CharSequence constraint,
Filter.FilterResults results)
FilterInvoked in the UI thread to publish the filtering results in the
user interface. Subclasses must implement this method to display the
results computed in Filter.performFiltering(java.lang.CharSequence).
publishResults in class Filterconstraint - the constraint used to filter the dataresults - the results of the filtering operationFilter.filter(CharSequence, android.widget.Filter.FilterListener),
Filter.performFiltering(CharSequence),
Filter.FilterResults
|
Build 1.0_r1(from source) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||