public class JSONPrettyPrint extends JSONAbstractVisitor
| Constructor and Description |
|---|
JSONPrettyPrint() |
JSONPrettyPrint(char tab) |
| Modifier and Type | Method and Description |
|---|---|
void |
enterJSONArray(JSONArray<? extends JSON> arr) |
void |
enterJSONObject(JSONObject obj) |
void |
exitJSONArray(JSONArray<? extends JSON> arr) |
void |
exitJSONObject(JSONObject obj) |
java.lang.String |
prettyPrint()
Returns the visited JSON object as formatted code.
|
void |
visitJSONBoolean(JSONBoolean el) |
void |
visitJSONInteger(JSONInteger el) |
void |
visitJSONProperty(JSONObject.Property prop) |
void |
visitJSONString(JSONString el) |
public JSONPrettyPrint()
public JSONPrettyPrint(char tab)
public void visitJSONString(JSONString el)
visitJSONString in interface JSONVisitorvisitJSONString in class JSONAbstractVisitorpublic void visitJSONBoolean(JSONBoolean el)
visitJSONBoolean in interface JSONVisitorvisitJSONBoolean in class JSONAbstractVisitorpublic void visitJSONInteger(JSONInteger el)
visitJSONInteger in interface JSONVisitorvisitJSONInteger in class JSONAbstractVisitorpublic void enterJSONArray(JSONArray<? extends JSON> arr)
enterJSONArray in interface JSONVisitorenterJSONArray in class JSONAbstractVisitorpublic void exitJSONArray(JSONArray<? extends JSON> arr)
exitJSONArray in interface JSONVisitorexitJSONArray in class JSONAbstractVisitorpublic void enterJSONObject(JSONObject obj)
enterJSONObject in interface JSONVisitorenterJSONObject in class JSONAbstractVisitorpublic void visitJSONProperty(JSONObject.Property prop)
visitJSONProperty in interface JSONVisitorvisitJSONProperty in class JSONAbstractVisitorpublic void exitJSONObject(JSONObject obj)
exitJSONObject in interface JSONVisitorexitJSONObject in class JSONAbstractVisitorpublic java.lang.String prettyPrint()