public class

JSONNumber

extends JSONValue
java.lang.Object
   ↳ com.google.gwt.json.client.JSONValue
     ↳ com.google.gwt.json.client.JSONNumber

Class Overview

Represents a JSON number. Numbers are represented by doubles.

Summary

Public Constructors
JSONNumber(double value)
Creates a new JSONNumber from the double value.
Public Methods
double doubleValue()
Gets the double value this JSONNumber represents.
boolean equals(Object other)
double getValue()
This method is deprecated. See doubleValue()
int hashCode()
JSONNumber isNumber()
Returns this, as this is a JSONNumber.
String toString()
Returns the JSON representation of this number.
[Expand]
Inherited Methods
From class com.google.gwt.json.client.JSONValue
From class java.lang.Object

Public Constructors

public JSONNumber (double value)

Creates a new JSONNumber from the double value.

Public Methods

public double doubleValue ()

Gets the double value this JSONNumber represents.

public boolean equals (Object other)

public double getValue ()

This method is deprecated.
See doubleValue()

Gets the double value this JSONNumber represents.

public int hashCode ()

public JSONNumber isNumber ()

Returns this, as this is a JSONNumber.

Returns
  • a reference to a JSONNumber if this JSONValue is a JSONNumber or null otherwise.

public String toString ()

Returns the JSON representation of this number.