org.apache.wink.json4j.compat.impl
Class ApacheJSONObjectDelegate
java.lang.Object
org.apache.wink.json4j.compat.impl.ApacheJSONObjectDelegate
- All Implemented Interfaces:
- JSONObject
public class ApacheJSONObjectDelegate
- extends Object
- implements JSONObject
Method Summary |
JSONObject |
append(String key,
Object value)
|
Object |
get(String key)
|
boolean |
getBoolean(String key)
|
double |
getDouble(String key)
|
int |
getInt(String key)
|
JSONArray |
getJSONArray(String key)
|
JSONObject |
getJSONObject(String key)
|
long |
getLong(String key)
|
short |
getShort(String key)
|
String |
getString(String key)
|
boolean |
has(String key)
|
boolean |
isNull(String key)
|
Iterator |
keys()
|
int |
length()
|
JSONArray |
names()
|
JSONObject |
put(String key,
boolean value)
|
JSONObject |
put(String key,
Collection value)
|
JSONObject |
put(String key,
double value)
|
JSONObject |
put(String key,
int value)
|
JSONObject |
put(String key,
JSONObject value)
|
JSONObject |
put(String key,
long value)
|
JSONObject |
put(String key,
Map value)
|
JSONObject |
put(String key,
Object value)
|
JSONObject |
put(String key,
short value)
|
Object |
remove(String key)
|
Iterator |
sortedKeys()
|
String |
toString()
|
String |
toString(int indent)
|
Writer |
write(Writer w)
|
delegate
protected JSONObject delegate
ApacheJSONObjectDelegate
public ApacheJSONObjectDelegate()
ApacheJSONObjectDelegate
public ApacheJSONObjectDelegate(JSONObject jObj)
get
public Object get(String key)
- Specified by:
get
in interface JSONObject
getBoolean
public boolean getBoolean(String key)
throws JSONException
- Specified by:
getBoolean
in interface JSONObject
- Throws:
JSONException
getDouble
public double getDouble(String key)
throws JSONException
- Specified by:
getDouble
in interface JSONObject
- Throws:
JSONException
getInt
public int getInt(String key)
throws JSONException
- Specified by:
getInt
in interface JSONObject
- Throws:
JSONException
getLong
public long getLong(String key)
throws JSONException
- Specified by:
getLong
in interface JSONObject
- Throws:
JSONException
getShort
public short getShort(String key)
throws JSONException
- Specified by:
getShort
in interface JSONObject
- Throws:
JSONException
getString
public String getString(String key)
throws JSONException
- Specified by:
getString
in interface JSONObject
- Throws:
JSONException
getJSONObject
public JSONObject getJSONObject(String key)
throws JSONException
- Specified by:
getJSONObject
in interface JSONObject
- Throws:
JSONException
getJSONArray
public JSONArray getJSONArray(String key)
- Specified by:
getJSONArray
in interface JSONObject
append
public JSONObject append(String key,
Object value)
throws JSONException
- Specified by:
append
in interface JSONObject
- Throws:
JSONException
put
public JSONObject put(String key,
boolean value)
- Specified by:
put
in interface JSONObject
put
public JSONObject put(String key,
Collection value)
throws JSONException
- Specified by:
put
in interface JSONObject
- Throws:
JSONException
put
public JSONObject put(String key,
double value)
- Specified by:
put
in interface JSONObject
put
public JSONObject put(String key,
int value)
- Specified by:
put
in interface JSONObject
put
public JSONObject put(String key,
long value)
- Specified by:
put
in interface JSONObject
put
public JSONObject put(String key,
JSONObject value)
put
public JSONObject put(String key,
short value)
- Specified by:
put
in interface JSONObject
put
public JSONObject put(String key,
Map value)
throws JSONException
- Specified by:
put
in interface JSONObject
- Throws:
JSONException
put
public JSONObject put(String key,
Object value)
throws JSONException
- Specified by:
put
in interface JSONObject
- Throws:
JSONException
remove
public Object remove(String key)
- Specified by:
remove
in interface JSONObject
has
public boolean has(String key)
- Specified by:
has
in interface JSONObject
isNull
public boolean isNull(String key)
- Specified by:
isNull
in interface JSONObject
keys
public Iterator keys()
- Specified by:
keys
in interface JSONObject
sortedKeys
public Iterator sortedKeys()
- Specified by:
sortedKeys
in interface JSONObject
length
public int length()
- Specified by:
length
in interface JSONObject
names
public JSONArray names()
- Specified by:
names
in interface JSONObject
toString
public String toString()
- Specified by:
toString
in interface JSONObject
- Overrides:
toString
in class Object
toString
public String toString(int indent)
- Specified by:
toString
in interface JSONObject
write
public Writer write(Writer w)
throws JSONException
- Specified by:
write
in interface JSONObject
- Throws:
JSONException
Copyright © 2009-2012 The Apache Software Foundation. All Rights Reserved.