Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Return ObjectNode from ObjectNode set-methods in order to allow better chaining #1781

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -354,7 +354,7 @@ public void serializeWithType(JsonGenerator g, SerializerProvider provider,
*
* @since 2.1
*/
public JsonNode set(String fieldName, JsonNode value)
public ObjectNode set(String fieldName, JsonNode value)
{
if (value == null) {
value = nullNode();
Expand All @@ -373,7 +373,7 @@ public JsonNode set(String fieldName, JsonNode value)
*
* @since 2.1
*/
public JsonNode setAll(Map<String,? extends JsonNode> properties)
public ObjectNode setAll(Map<String,? extends JsonNode> properties)
{
for (Map.Entry<String,? extends JsonNode> en : properties.entrySet()) {
JsonNode n = en.getValue();
Expand All @@ -395,7 +395,7 @@ public JsonNode setAll(Map<String,? extends JsonNode> properties)
*
* @since 2.1
*/
public JsonNode setAll(ObjectNode other)
public ObjectNode setAll(ObjectNode other)
{
_children.putAll(other._children);
return this;
Expand Down