다음을 통해 공유


NumberFormat.IntegerInstance Property

Definition

Returns an integer number format for the current default java.util.Locale.Category#FORMAT FORMAT locale.

public static Java.Text.NumberFormat IntegerInstance { [Android.Runtime.Register("getIntegerInstance", "()Ljava/text/NumberFormat;", "")] get; }
[<get: Android.Runtime.Register("getIntegerInstance", "()Ljava/text/NumberFormat;", "")>]
static member IntegerInstance : Java.Text.NumberFormat

Property Value

a number format for integer values

Attributes

Remarks

Returns an integer number format for the current default java.util.Locale.Category#FORMAT FORMAT locale. The returned number format is configured to round floating point numbers to the nearest integer using half-even rounding (see java.math.RoundingMode#HALF_EVEN RoundingMode.HALF_EVEN) for formatting, and to parse only the integer part of an input string (see #isParseIntegerOnly isParseIntegerOnly).

This is equivalent to calling #getIntegerInstance(Locale) getIntegerInstance(Locale.getDefault(Locale.Category.FORMAT)).

Added in 1.4.

Java documentation for java.text.NumberFormat.getIntegerInstance().

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