Read, write and transform stream examples for node.
Readable stream of objects. Source data is found in the data-sources
folder (created by create-source.js
).
Writable stream that outputs incoming objects to the console.
Writable stream that outputs incoming objects to the console then delays 2 seconds.
Transform stream that stores the original value
in originalValue
and increments the value
field.
Transform stream that filters out objects whose value
is 0.
Demonstrates aforementioned ReadStream
in flowing and non-flowing modes.
Demonstrates pause()
and resume()
in flowing mode streams.
Pipes ReadStream
to WriteStream
.
Pipes ReadStream
into TransformStream
and then into WriteStream
.
Pipes ReadStream
into TransformFilterStream
and then into WriteStream
.