ChoiceFormat.SetChoices(Double[], String[]) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Set the choices to be used in formatting.
[Android.Runtime.Register("setChoices", "([D[Ljava/lang/String;)V", "GetSetChoices_arrayDarrayLjava_lang_String_Handler")]
public virtual void SetChoices (double[]? limits, string[]? formats);
[<Android.Runtime.Register("setChoices", "([D[Ljava/lang/String;)V", "GetSetChoices_arrayDarrayLjava_lang_String_Handler")>]
abstract member SetChoices : double[] * string[] -> unit
override this.SetChoices : double[] * string[] -> unit
Parameters
- limits
- Double[]
contains the top value that you want parsed with that format, and should be in ascending sorted order. When formatting X, the choice will be the i, where limit[i] ≤ X < limit[i+1]. If the limit array is not in ascending order, the results of formatting will be incorrect.
- formats
- String[]
are the formats you want to use for each limit. They can be either Format objects or Strings. When formatting with object Y, if the object is a NumberFormat, then ((NumberFormat) Y).format(X) is called. Otherwise Y.toString() is called.
- Attributes
Remarks
Set the choices to be used in formatting.
Java documentation for java.text.ChoiceFormat.setChoices(double[], 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.