Interface JsonBuilder
-
- All Known Implementing Classes:
MapJsonBuilder,StringJsonBuilder
public interface JsonBuilderBuilds JSON objects- Author:
- Michel Kraemer
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description JsonBuilderadd(String name, Object o)Adds a property to the object to buildObjectbuild()Builds the JSON objectObjecttoJson(Object o)Converts the given object to a JSON object
-
-
-
Method Detail
-
add
JsonBuilder add(String name, Object o)
Adds a property to the object to build- Parameters:
name- the property's nameo- the property's value- Returns:
- the
JsonBuilder
-
build
Object build()
Builds the JSON object- Returns:
- the object
-
-