Items are emitted in source order and the feed ends as soon as the quota is met, leaving the rest of the source
unconsumed.
Note
Incremental: items are emitted as they are drawn and the reported feed ends at n items, whatever the feed
drawn from, which is the standard way to bound an infinite feed.
Streaming: items are emitted one at a time, none retained.
Stateful: the quota is counted over the items drawn, so a task invoked per nested feed or per run grants
its quota to each rather than to the feed as a whole.
Type Parameters
V
The type of items in the feed
Parameters
n: number
The maximum number of leading items to emit; values less than 1 empty the feed
Creates a task truncating the feed to a prefix.
Items are emitted in source order and the feed ends as soon as the quota is met, leaving the rest of the source unconsumed.
nitems, whatever the feed drawn from, which is the standard way to bound an infinite feed.