Udostępnij za pośrednictwem


ChronoField.CheckValidIntValue(Int64) Method

Definition

Checks that the specified value is valid and fits in an int.

[Android.Runtime.Register("checkValidIntValue", "(J)I", "", ApiSince=26)]
public int CheckValidIntValue (long value);
[<Android.Runtime.Register("checkValidIntValue", "(J)I", "", ApiSince=26)>]
member this.CheckValidIntValue : int64 -> int

Parameters

value
Int64

the value to check

Returns

the value that was passed in

Attributes

Remarks

Checks that the specified value is valid and fits in an int.

This validates that the value is within the outer range of valid values returned by #range(). It also checks that all valid values are within the bounds of an int.

This method checks against the range of the field in the ISO-8601 calendar system. This range may be incorrect for other calendar systems. Use Chronology#range(ChronoField) to access the correct range for a different calendar system.

Java documentation for java.time.temporal.ChronoField.checkValidIntValue(long).

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