Share via


JsonReader.NextLong Method

Definition

Returns the JsonToken#NUMBER long value of the next token, consuming it.

[Android.Runtime.Register("nextLong", "()J", "")]
public long NextLong ();
[<Android.Runtime.Register("nextLong", "()J", "")>]
member this.NextLong : unit -> int64

Returns

Attributes

Exceptions

if the next token is not a literal value.

if the next literal value cannot be parsed as a number, or exactly represented as a long.

Remarks

Returns the JsonToken#NUMBER long value of the next token, consuming it. If the next token is a string, this method will attempt to parse it as a long. If the next token's numeric value cannot be exactly represented by a Java long, this method throws.

Java documentation for android.util.JsonReader.nextLong().

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