Package org.apache.calcite.util
Class JsonBuilder
java.lang.Object
org.apache.calcite.util.JsonBuilder
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionvoidappend(StringBuilder buf, int indent, @Nullable Object o) Appends a JSON object to a string builder.list()Creates a JSON object (represented by aList).map()Creates a JSON object (represented by aMap).Adds a key/value pair to a JSON object.Adds a key/value pair to a JSON object if the value is not null.Serializes an object consisting of maps, lists and atoms into a JSON string.
- 
Constructor Details- 
JsonBuilderpublic JsonBuilder()
 
- 
- 
Method Details- 
mapCreates a JSON object (represented by aMap).
- 
listCreates a JSON object (represented by aList).
- 
putAdds a key/value pair to a JSON object.
- 
putIfAdds a key/value pair to a JSON object if the value is not null.
- 
toJsonStringSerializes an object consisting of maps, lists and atoms into a JSON string.We should use a JSON library such as Jackson when Mondrian needs one elsewhere. 
- 
appendAppends a JSON object to a string builder.
 
-