public class

JsonObject

extends Object
implements Json
java.lang.Object
   ↳ com.atlassian.confluence.json.json.JsonObject

Summary

Public Constructors
JsonObject()
Public Methods
String serialize()
Returns a JSON-format string representation of this object.
JsonObject setProperty(String key, Date date)
JsonObject setProperty(String key, Number number)
JsonObject setProperty(String key, Json json)
JsonObject setProperty(String key, String value)
[Expand]
Inherited Methods
From class java.lang.Object
From interface com.atlassian.confluence.json.json.Json

Public Constructors

public JsonObject ()

Public Methods

public String serialize ()

Returns a JSON-format string representation of this object.

The string must evaluate in a Javascript engine; i.e. it must be a valid RHS for the Javascript expression: { data : RHS }

Thus, nulls, booleans, numbers, strings, arrays and objects should be supported by implementing classes.

Closures must not be returned with this method.

Returns
  • json-format representation of this object

public JsonObject setProperty (String key, Date date)

public JsonObject setProperty (String key, Number number)

public JsonObject setProperty (String key, Json json)

public JsonObject setProperty (String key, String value)