Język

AppSearchResult.NewFailedResult(Int32, String) Method

Definition

Creates an AppSearchResult with the supplied result code and message.

[Android.Runtime.Register("newFailedResult", "(ILjava/lang/String;)Landroid/app/appsearch/AppSearchResult;", "", ApiSince=31)]
[Java.Interop.JavaTypeParameters(new System.String[] { "ValueType" })]
public static Android.App.AppSearch.AppSearchResult NewFailedResult(int resultCode, string? errorMessage);
[<Android.Runtime.Register("newFailedResult", "(ILjava/lang/String;)Landroid/app/appsearch/AppSearchResult;", "", ApiSince=31)>]
[<Java.Interop.JavaTypeParameters(new System.String[] { "ValueType" })>]
static member NewFailedResult : int * string -> Android.App.AppSearch.AppSearchResult

Parameters

resultCode
Int32

One of the constants documented in AppSearchResult#getResultCode.

errorMessage
String

An optional string describing the reason or nature of the failure.

Returns

A result with the supplied code and message and no result value. If the code is RESULT_OK, the result reports success.

Attributes

Remarks

Creates an AppSearchResult with the supplied result code and message.

Java documentation for android.app.appsearch.AppSearchResult.newFailedResult(int, java.lang.String).

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