Udostępnij za pośrednictwem


CursorAdapter.RunQueryOnBackgroundThread Method

Definition

Overloads

RunQueryOnBackgroundThread(ICharSequence)

Runs a query with the specified constraint.

RunQueryOnBackgroundThread(String)

Runs a query with the specified constraint.

RunQueryOnBackgroundThread(ICharSequence)

Runs a query with the specified constraint.

[Android.Runtime.Register("runQueryOnBackgroundThread", "(Ljava/lang/CharSequence;)Landroid/database/Cursor;", "GetRunQueryOnBackgroundThread_Ljava_lang_CharSequence_Handler")]
public virtual Android.Database.ICursor? RunQueryOnBackgroundThread (Java.Lang.ICharSequence? constraint);
[<Android.Runtime.Register("runQueryOnBackgroundThread", "(Ljava/lang/CharSequence;)Landroid/database/Cursor;", "GetRunQueryOnBackgroundThread_Ljava_lang_CharSequence_Handler")>]
abstract member RunQueryOnBackgroundThread : Java.Lang.ICharSequence -> Android.Database.ICursor
override this.RunQueryOnBackgroundThread : Java.Lang.ICharSequence -> Android.Database.ICursor

Parameters

constraint
ICharSequence

the constraint with which the query must be filtered

Returns

a Cursor representing the results of the new query

Attributes

Remarks

Runs a query with the specified constraint. This query is requested by the filter attached to this adapter.

The query is provided by a android.widget.FilterQueryProvider. If no provider is specified, the current cursor is not filtered and returned.

After this method returns the resulting cursor is passed to #changeCursor(Cursor) and the previous cursor is closed.

This method is always executed on a background thread, not on the application's main thread (or UI thread.)

Contract: when constraint is null or empty, the original results, prior to any filtering, must be returned.

Java documentation for android.widget.CursorAdapter.runQueryOnBackgroundThread(java.lang.CharSequence).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

See also

Applies to

RunQueryOnBackgroundThread(String)

Runs a query with the specified constraint.

public Android.Database.ICursor? RunQueryOnBackgroundThread (string? constraint);
member this.RunQueryOnBackgroundThread : string -> Android.Database.ICursor

Parameters

constraint
String

the constraint with which the query must be filtered

Returns

a Cursor representing the results of the new query

Remarks

Runs a query with the specified constraint. This query is requested by the filter attached to this adapter.

The query is provided by a android.widget.FilterQueryProvider. If no provider is specified, the current cursor is not filtered and returned.

After this method returns the resulting cursor is passed to #changeCursor(Cursor) and the previous cursor is closed.

This method is always executed on a background thread, not on the application's main thread (or UI thread.)

Contract: when constraint is null or empty, the original results, prior to any filtering, must be returned.

Java documentation for android.widget.CursorAdapter.runQueryOnBackgroundThread(java.lang.CharSequence).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to