Compartilhar via


LauncherApps.ResolveActivity(Intent, UserHandle) Method

Definition

Returns the activity info for a given intent and user handle, if it resolves.

[Android.Runtime.Register("resolveActivity", "(Landroid/content/Intent;Landroid/os/UserHandle;)Landroid/content/pm/LauncherActivityInfo;", "GetResolveActivity_Landroid_content_Intent_Landroid_os_UserHandle_Handler")]
public virtual Android.Content.PM.LauncherActivityInfo? ResolveActivity (Android.Content.Intent? intent, Android.OS.UserHandle? user);
[<Android.Runtime.Register("resolveActivity", "(Landroid/content/Intent;Landroid/os/UserHandle;)Landroid/content/pm/LauncherActivityInfo;", "GetResolveActivity_Landroid_content_Intent_Landroid_os_UserHandle_Handler")>]
abstract member ResolveActivity : Android.Content.Intent * Android.OS.UserHandle -> Android.Content.PM.LauncherActivityInfo
override this.ResolveActivity : Android.Content.Intent * Android.OS.UserHandle -> Android.Content.PM.LauncherActivityInfo

Parameters

intent
Intent

The intent to find a match for.

user
UserHandle

The profile to look in for a match.

Returns

An activity info object if there is a match.

Attributes

Remarks

Returns the activity info for a given intent and user handle, if it resolves. Otherwise it returns null.

Java documentation for android.content.pm.LauncherApps.resolveActivity(android.content.Intent, android.os.UserHandle).

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