Share via


AppSearchSession.GetByDocumentId Method

Definition

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

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

Parameters

request
GetByDocumentIdRequest

a request containing a namespace and IDs to get documents for.

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 IDs. The values are the returned GenericDocuments 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.getByDocumentId(android.app.appsearch.GetByDocumentIdRequest, java.util.concurrent.Executor, android.app.appsearch.BatchResultCallback<java.lang.String, android.app.appsearch.GenericDocument>).

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