|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectikrs.json.parser.DefaultJSONValueFactory
public class DefaultJSONValueFactory
A default JSONValueFactory implementation which is meant to be subclassed. All methods just create new JSONValues, except createNull(...) which returns JSONValue.NULL: - createArray(...) returns 'new JSONArray()' - createNumber(...) returns 'new JSONumber(...)' - createBoolean(...) returns 'new JSONBoolean(...)' - ... and so on ...
| Constructor Summary | |
|---|---|
DefaultJSONValueFactory()
Creates a new default JSONValueFactory. |
|
| Method Summary | |
|---|---|
JSONArray |
createArray()
This method creates a non-embedded JSON array (first single value from the input). |
JSONArray |
createArray(int arrayIndex)
This method creates a JSON array embedded inside a different JSON array. |
JSONArray |
createArray(java.lang.String memberName)
This method creates a JSON array embedded inside a different JSON object. |
JSONBoolean |
createBoolean(java.lang.Boolean bool)
This method creates a non-embedded JSON boolean (first single value from the input). |
JSONBoolean |
createBoolean(java.lang.Boolean bool,
int arrayIndex)
This method creates a JSON boolean embedded inside a JSON array. |
JSONBoolean |
createBoolean(java.lang.Boolean bool,
java.lang.String memberName)
This method creates a JSON boolean embedded inside a JSON object. |
JSONNull |
createNull()
This method creates a non-embedded JSON null (first single value from the input). |
JSONNull |
createNull(int arrayIndex)
This method creates a JSON null embedded inside a JSON array. |
JSONNull |
createNull(java.lang.String memberName)
This method creates a JSON null embedded inside a JSON object. |
JSONNumber |
createNumber(java.lang.Number number)
This method creates a non-embedded JSON number (first single value from the input). |
JSONNumber |
createNumber(java.lang.Number number,
int arrayIndex)
This method creates a JSON number embedded inside a JSON array. |
JSONNumber |
createNumber(java.lang.Number number,
java.lang.String memberName)
This method creates a JSON number embedded inside a JSON object. |
JSONObject |
createObject()
This method creates a non-embedded JSON object (first single value from the input). |
JSONObject |
createObject(int arraIndex)
This method creates a JSON object embedded inside a different JSON object. |
JSONObject |
createObject(java.lang.String memberName)
This method creates a JSON object embedded inside a different JSON object. |
JSONString |
createString(java.lang.String str)
This method creates a non-embedded JSON string (first single value from the input). |
JSONString |
createString(java.lang.String str,
int arrayIndex)
This method creates a JSON string embedded inside a JSON array. |
JSONString |
createString(java.lang.String str,
java.lang.String memberName)
This method creates a JSON string embedded inside a JSON object. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DefaultJSONValueFactory()
| Method Detail |
|---|
public JSONNumber createNumber(java.lang.Number number)
createNumber in interface JSONValueFactory
public JSONNumber createNumber(java.lang.Number number,
int arrayIndex)
createNumber in interface JSONValueFactoryarrayIndex - The superior array's index where the new
element is located.
public JSONNumber createNumber(java.lang.Number number,
java.lang.String memberName)
createNumber in interface JSONValueFactorymemberName - The new number's member name inside the
superior object.
public JSONBoolean createBoolean(java.lang.Boolean bool)
createBoolean in interface JSONValueFactory
public JSONBoolean createBoolean(java.lang.Boolean bool,
int arrayIndex)
createBoolean in interface JSONValueFactoryarrayIndex - The superior array's index where the new
element is located.
public JSONBoolean createBoolean(java.lang.Boolean bool,
java.lang.String memberName)
createBoolean in interface JSONValueFactorymemberName - The new boolean's member name inside the
superior object.
public JSONString createString(java.lang.String str)
createString in interface JSONValueFactory
public JSONString createString(java.lang.String str,
int arrayIndex)
createString in interface JSONValueFactoryarrayIndex - The superior array's index where the new
element is located.
public JSONString createString(java.lang.String str,
java.lang.String memberName)
createString in interface JSONValueFactorymemberName - The new boolean's member name inside the
superior object.
public JSONNull createNull()
createNull in interface JSONValueFactorypublic JSONNull createNull(int arrayIndex)
createNull in interface JSONValueFactoryarrayIndex - The superior array's index where the new
element is located.
public JSONNull createNull(java.lang.String memberName)
createNull in interface JSONValueFactorymemberName - The new null's member name inside the
superior object.
public JSONArray createArray()
createArray in interface JSONValueFactorypublic JSONArray createArray(int arrayIndex)
createArray in interface JSONValueFactoryarrayIndex - The superior array's index where the new
element is located.
public JSONArray createArray(java.lang.String memberName)
createArray in interface JSONValueFactorymemberName - The new array's member name inside the
superior object.
public JSONObject createObject()
createObject in interface JSONValueFactorypublic JSONObject createObject(int arraIndex)
createObject in interface JSONValueFactoryarrayIndex - The superior array's index where the new
element is located.
public JSONObject createObject(java.lang.String memberName)
createObject in interface JSONValueFactorymemberName - The new object's member name inside the
superior object.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||