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

Add MoreCollectors.toBatches collector #44

Open
5 tasks
amaembo opened this issue Dec 22, 2015 · 0 comments
Open
5 tasks

Add MoreCollectors.toBatches collector #44

amaembo opened this issue Dec 22, 2015 · 0 comments

Comments

@amaembo
Copy link
Owner

amaembo commented Dec 22, 2015

There's repeating requests to add a partitioning of the stream to the fixed size batches. See, for example, this question. Some problems can be solved using StreamEx.ofSubLists, but sometimes the source is not a random access list. It's hardly possible to create efficient parallel implementation for ordered batches, but if we don't guarantee an order (any subset of input elements may be collected into single batch), then implementation becomes quite straightforward. Probably it's a good idea to add such collector.

  • Implementation
  • Tests
  • JavaDoc
  • Changes
  • Cheatsheet
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant