Creates a task executing a side effect for each item without modifying the stream.
Items are processed sequentially and output order is preserved. Useful for debugging or monitoring items as they flow through the pipeline.
The type of items in the stream
The function to execute for each item (return value is ignored)
A task that executes the consumer for each item
Creates a task executing a side effect for each item without modifying the stream.
Items are processed sequentially and output order is preserved. Useful for debugging or monitoring items as they flow through the pipeline.