java.lang.Object
com.espertech.esper.common.client.json.minimaljson.JsonValue
com.espertech.esper.common.client.json.minimaljson.JsonString
All Implemented Interfaces:
Serializable

public class JsonString extends JsonValue
See Also:
  • Constructor Details

    • JsonString

      public JsonString(String string)
      Ctor.
      Parameters:
      string - value (non-null)
  • Method Details

    • isString

      public boolean isString()
      Description copied from class: JsonValue
      Detects whether this value represents a JSON string.
      Overrides:
      isString in class JsonValue
      Returns:
      true if this value represents a JSON string
    • asString

      public String asString()
      Description copied from class: JsonValue
      Returns this JSON value as String, assuming that this value represents a JSON string. If this is not the case, an exception is thrown.
      Overrides:
      asString in class JsonValue
      Returns:
      the string represented by this value
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class JsonValue
    • equals

      public boolean equals(Object object)
      Description copied from class: JsonValue
      Indicates whether some other object is "equal to" this one according to the contract specified in Object.equals(Object).

      Two JsonValues are considered equal if and only if they represent the same JSON text. As a consequence, two given JsonObjects may be different even though they contain the same set of names with the same values, but in a different order.

      Overrides:
      equals in class JsonValue
      Parameters:
      object - the reference object with which to compare
      Returns:
      true if this object is the same as the object argument; false otherwise