次の方法で共有


Collator.GetCollationKey(String) Method

Definition

Transforms the String into a CollationKey suitable for efficient repeated comparison.

[Android.Runtime.Register("getCollationKey", "(Ljava/lang/String;)Landroid/icu/text/CollationKey;", "GetGetCollationKey_Ljava_lang_String_Handler", ApiSince=24)]
public abstract Android.Icu.Text.CollationKey? GetCollationKey (string? source);
[<Android.Runtime.Register("getCollationKey", "(Ljava/lang/String;)Landroid/icu/text/CollationKey;", "GetGetCollationKey_Ljava_lang_String_Handler", ApiSince=24)>]
abstract member GetCollationKey : string -> Android.Icu.Text.CollationKey

Parameters

source
String

the string to be transformed into a CollationKey.

Returns

the CollationKey for the given String based on this Collator's collation rules. If the source String is null, a null CollationKey is returned.

Attributes

Remarks

Transforms the String into a CollationKey suitable for efficient repeated comparison. The resulting key depends on the collator's rules, strength and decomposition mode.

Note that collation keys are often less efficient than simply doing comparison. For more details, see the ICU User Guide.

See the CollationKey class documentation for more information.

Java documentation for android.icu.text.Collator.getCollationKey(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