JSONNumber (GWT Javadoc)

Overview | Package | Class | Use | Deprecated | Help
| GWT 2.7.0
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.google.gwt.json.client
Class JSONNumber

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

    public class JSONNumber

extends JSONValue

Represents a JSON number. Numbers are represented by `double`s.

Constructor Summary
`JSONNumber(double value)` Creates a new JSONNumber from the double value.

Method Summary
`double` | `doubleValue()` Gets the double value this JSONNumber represents.
`boolean` | `equals(java.lang.Object other)`
`(package private) JavaScriptObject` | `getUnwrapper()` Internal.
`double` | `getValue()` Deprecated. See `doubleValue()`
`int` | `hashCode()`
`JSONNumber` | `isNumber()` Returns `this`, as this is a JSONNumber.
`java.lang.String` | `toString()` Returns the JSON representation of this number.

Methods inherited from class com.google.gwt.json.client.JSONValue
`isArray, isBoolean, isNull, isObject, isString`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Constructor Detail

### JSONNumber

    public JSONNumber(double value)

  Creates a new JSONNumber from the double value.

Method Detail

### doubleValue

    public double doubleValue()

  Gets the double value this JSONNumber represents.

### equals

    public boolean equals(java.lang.Object other)

  Overrides:
    `equals` in class `java.lang.Object`

### getValue

    @Deprecated
    public double getValue()

  Deprecated. See `doubleValue()`

  Gets the double value this JSONNumber represents.

### hashCode

    public int hashCode()

  Overrides:
    `hashCode` in class `java.lang.Object`

### isNumber

    public JSONNumber isNumber()

  Returns `this`, as this is a JSONNumber.

  Overrides:
    `isNumber` in class `JSONValue`
  Returns:
    a reference to a JSONNumber if this JSONValue is a JSONNumber or `null` otherwise.

### toString

    public java.lang.String toString()

  Returns the JSON representation of this number.

  Specified by:
    `toString` in class `JSONValue`

### getUnwrapper

    JavaScriptObject getUnwrapper()

  Description copied from class: `JSONValue`
  Internal. Returns a JS func that can unwrap this value. Used from native code.

  Specified by:
    `getUnwrapper` in class `JSONValue`

Overview | Package | Class | Use | Deprecated | Help
| GWT 2.7.0
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD