Class JreJsonNumber

    • Constructor Detail

      • JreJsonNumber

        public JreJsonNumber​(double number)
    • Method Detail

      • asBoolean

        public boolean asBoolean()
        Description copied from interface: JsonValue
        Coerces underlying value to boolean according to the rules of Javascript coercion.
        Specified by:
        asBoolean in interface JsonValue
      • asNumber

        public double asNumber()
        Description copied from interface: JsonValue
        Coerces the underlying value to a number according to the rules of Javascript coercion.
        Specified by:
        asNumber in interface JsonValue
      • asString

        public String asString()
        Description copied from interface: JsonValue
        Coerces the underlying value to a String according to the rules of JavaScript coercion.
        Specified by:
        asString in interface JsonValue
      • getType

        public JsonType getType()
        Description copied from interface: JsonValue
        Returns an enumeration representing the fundamental JSON type.
        Specified by:
        getType in interface JsonValue
      • jsEquals

        public boolean jsEquals​(JsonValue value)
        Description copied from interface: JsonValue
        Equivalent of Javascript '==' operator comparison between two values.
        Specified by:
        jsEquals in interface JsonValue
      • traverse

        public void traverse​(elemental.json.impl.JsonVisitor visitor,
                             elemental.json.impl.JsonContext ctx)
        Specified by:
        traverse in class JreJsonValue
      • toJson

        public String toJson()
        Description copied from interface: JsonValue
        Returns a serialized JSON string representing this value.
        Specified by:
        toJson in interface JsonValue
        Returns: