Package kong.unirest.gson
Class GsonObject
- java.lang.Object
-
- kong.unirest.gson.GsonElement<com.google.gson.JsonObject>
-
- kong.unirest.gson.GsonObject
-
- All Implemented Interfaces:
JsonEngine.Element
,JsonEngine.Object
public class GsonObject extends GsonElement<com.google.gson.JsonObject> implements JsonEngine.Object
-
-
Field Summary
-
Fields inherited from class kong.unirest.gson.GsonElement
element
-
-
Constructor Summary
Constructors Constructor Description GsonObject()
GsonObject(com.google.gson.JsonObject element)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description <E extends java.lang.Enum>
voidadd(java.lang.String key, E enumvalue)
void
add(java.lang.String key, JsonEngine.Element value)
void
addProperty(java.lang.String key, java.lang.Boolean value)
void
addProperty(java.lang.String key, java.lang.Number value)
void
addProperty(java.lang.String key, java.lang.String value)
void
addProperty(java.lang.String key, JsonEngine.Element value)
JsonEngine.Element
get(java.lang.String key)
boolean
has(java.lang.String key)
java.util.Set<java.lang.String>
keySet()
void
remove(java.lang.String key)
int
size()
-
Methods inherited from class kong.unirest.gson.GsonElement
equals, getAsBigDecimal, getAsBigInteger, getAsBoolean, getAsDouble, getAsFloat, getAsInt, getAsJsonArray, getAsJsonObject, getAsJsonPrimitive, getAsLong, getAsPrimitive, getAsString, getEngineElement, hashCode, isJsonArray, isJsonNull, isJsonObject, isJsonPrimitive
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface kong.unirest.core.json.JsonEngine.Element
getAsBigDecimal, getAsBigInteger, getAsBoolean, getAsDouble, getAsFloat, getAsInt, getAsJsonArray, getAsJsonObject, getAsJsonPrimitive, getAsLong, getAsPrimitive, getAsString, getEngineElement, isJsonArray, isJsonNull, isJsonObject, isJsonPrimitive
-
-
-
-
Method Detail
-
size
public int size()
- Specified by:
size
in interfaceJsonEngine.Object
-
has
public boolean has(java.lang.String key)
- Specified by:
has
in interfaceJsonEngine.Object
-
get
public JsonEngine.Element get(java.lang.String key)
- Specified by:
get
in interfaceJsonEngine.Object
-
add
public void add(java.lang.String key, JsonEngine.Element value)
- Specified by:
add
in interfaceJsonEngine.Object
-
addProperty
public void addProperty(java.lang.String key, java.lang.Boolean value)
- Specified by:
addProperty
in interfaceJsonEngine.Object
-
addProperty
public void addProperty(java.lang.String key, java.lang.String value)
- Specified by:
addProperty
in interfaceJsonEngine.Object
-
addProperty
public void addProperty(java.lang.String key, java.lang.Number value)
- Specified by:
addProperty
in interfaceJsonEngine.Object
-
addProperty
public void addProperty(java.lang.String key, JsonEngine.Element value)
- Specified by:
addProperty
in interfaceJsonEngine.Object
-
remove
public void remove(java.lang.String key)
- Specified by:
remove
in interfaceJsonEngine.Object
-
add
public <E extends java.lang.Enum> void add(java.lang.String key, E enumvalue)
- Specified by:
add
in interfaceJsonEngine.Object
-
keySet
public java.util.Set<java.lang.String> keySet()
- Specified by:
keySet
in interfaceJsonEngine.Object
-
-