Adds a member, which is a name-value pair, to self. The name must be a String, but the value can be an arbitrary JsonElement, thereby allowing you to build a full tree of JsonElements rooted at this node. @param property name of the member. @param value the member object.
(String property, JsonElement value)
| 54 | * @param value the member object. |
| 55 | */ |
| 56 | public void add(String property, JsonElement value) { |
| 57 | if (value == null) { |
| 58 | value = JsonNull.createJsonNull(); |
| 59 | } |
| 60 | members.put($Gson$Preconditions.checkNotNull(property), value); |
| 61 | } |
| 62 | |
| 63 | /** |
| 64 | * Removes the {@code property} from this {@link JsonObject}. |