AppSearchSession.Remove Method

Definition

Overloads

Remove(RemoveByDocumentIdRequest, IExecutor, IBatchResultCallback)

Removes GenericDocument objects by document IDs in a namespace from the AppSearchSession database.

Remove(String, SearchSpec, IExecutor, IConsumer)

Removes GenericDocuments from the index by Query.

Remove(RemoveByDocumentIdRequest, IExecutor, IBatchResultCallback)

Removes GenericDocument objects by document IDs in a namespace from the AppSearchSession database.

[Android.Runtime.Register("remove", "(Landroid/app/appsearch/RemoveByDocumentIdRequest;Ljava/util/concurrent/Executor;Landroid/app/appsearch/BatchResultCallback;)V", "", ApiSince=31)]
public void Remove (Android.App.AppSearch.RemoveByDocumentIdRequest request, Java.Util.Concurrent.IExecutor executor, Android.App.AppSearch.IBatchResultCallback callback);
[<Android.Runtime.Register("remove", "(Landroid/app/appsearch/RemoveByDocumentIdRequest;Ljava/util/concurrent/Executor;Landroid/app/appsearch/BatchResultCallback;)V", "", ApiSince=31)>]
member this.Remove : Android.App.AppSearch.RemoveByDocumentIdRequest * Java.Util.Concurrent.IExecutor * Android.App.AppSearch.IBatchResultCallback -> unit

Parameters

request
RemoveByDocumentIdRequest

RemoveByDocumentIdRequest with IDs in a namespace to remove from the index.

executor
IExecutor

Executor on which to invoke the callback.

callback
IBatchResultCallback

Callback to receive the pending result of performing this operation. The keys of the returned AppSearchBatchResult are the input document IDs. The values are null on success, or a failed AppSearchResult otherwise. IDs that are not found will return a failed AppSearchResult with a result code of AppSearchResult#RESULT_NOT_FOUND. If an unexpected internal error occurs in the AppSearch service, BatchResultCallback#onSystemError will be invoked with a Throwable.

Attributes

Remarks

Java documentation for android.app.appsearch.AppSearchSession.remove(android.app.appsearch.RemoveByDocumentIdRequest, java.util.concurrent.Executor, android.app.appsearch.BatchResultCallback<java.lang.String, java.lang.Void>).

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

Remove(String, SearchSpec, IExecutor, IConsumer)

Removes GenericDocuments from the index by Query.

[Android.Runtime.Register("remove", "(Ljava/lang/String;Landroid/app/appsearch/SearchSpec;Ljava/util/concurrent/Executor;Ljava/util/function/Consumer;)V", "", ApiSince=31)]
public void Remove (string queryExpression, Android.App.AppSearch.SearchSpec searchSpec, Java.Util.Concurrent.IExecutor executor, Java.Util.Functions.IConsumer callback);
[<Android.Runtime.Register("remove", "(Ljava/lang/String;Landroid/app/appsearch/SearchSpec;Ljava/util/concurrent/Executor;Ljava/util/function/Consumer;)V", "", ApiSince=31)>]
member this.Remove : string * Android.App.AppSearch.SearchSpec * Java.Util.Concurrent.IExecutor * Java.Util.Functions.IConsumer -> unit

Parameters

queryExpression
String

Query String to search.

searchSpec
SearchSpec

Spec containing schemaTypes, namespaces and query expression indicates how document will be removed. All specific about how to scoring, ordering, snippeting and resulting will be ignored.

executor
IExecutor

Executor on which to invoke the callback.

callback
IConsumer

Callback to receive errors resulting from removing the documents. If the operation succeeds, the callback will be invoked with null.

Attributes

Remarks

Java documentation for android.app.appsearch.AppSearchSession.remove(java.lang.String, android.app.appsearch.SearchSpec, java.util.concurrent.Executor, java.util.function.Consumer<android.app.appsearch.AppSearchResult<java.lang.Void>>).

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