You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Add basic Stream support in JsonNode: valueStream(), propertyStream(), forEachEntry()Β #4863
Currently use of Tree Model with Java 8 Streams is bit more complicated than necessary, since there are no java.util.stream.Stream producing methods in JsonNode. But it should be straight-forward at methods as follows:
Stream<JsonNode> JsonNode.valueStream(): for ArrayNode return Stream of all element JsonNodes; for ObjectNode return Stream of all values of child entries; for other nodes empty Stream
Stream<Map.Entry> JsonNode.propertyStream(): for ObjectNode return Stream of all properties (name, value pairs); for other nodes empty Stream
void JsonNode.forEachEntry(BiConsumer<String, JsonNode>): for ObjectNode calls consumer with all entries; for other nodes does nothing.
changed the title [-]Add basic Stream support in `JsonNode`: `valueStream()`, `entryStream()`, `forEachEntry()`[/-][+]Add basic Stream support in `JsonNode`: `valueStream()`, `propertyStream()`, `forEachEntry()`[/+]on Dec 28, 2024
Activity
Fix #4863: add basic `Stream` methods in `JsonNode`
Fix #4863: add basic `Stream` methods in `JsonNode` (#4864)
[-]Add basic Stream support in `JsonNode`: `valueStream()`, `entryStream()`, `forEachEntry()`[/-][+]Add basic Stream support in `JsonNode`: `valueStream()`, `propertyStream()`, `forEachEntry()`[/+]cowtowncoder commentedon Dec 28, 2024
NOTE: renamed
entryStream->propertyStreamas per naming guidance of JSTEP-6KAFKA-19336 Upgrade Jackson to 2.19.0 (#19835)