Language

ResolveInfo.DisplayNameComparator.Compare(ResolveInfo, ResolveInfo) Method

Definition

Checks target users before comparing current-user results' labels, using activity names when labels are missing.

[Android.Runtime.Register("compare", "(Landroid/content/pm/ResolveInfo;Landroid/content/pm/ResolveInfo;)I", "")]
public int Compare(Android.Content.PM.ResolveInfo? a, Android.Content.PM.ResolveInfo? b);
[<Android.Runtime.Register("compare", "(Landroid/content/pm/ResolveInfo;Landroid/content/pm/ResolveInfo;)I", "")>]
member this.Compare : Android.Content.PM.ResolveInfo * Android.Content.PM.ResolveInfo -> int

Parameters

a
ResolveInfo

The first resolution result to compare.

b
ResolveInfo

The second resolution result to compare.

Returns

One if the first result targets another user; otherwise, minus one if the second does. When both target the current user, returns the collator's result for their loaded labels, substituting each activity's name for a missing label.

Attributes

Remarks

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