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

Create primitiveStream methods for IntBag, LongBag and DoubleBag #1455

Open
donraab opened this issue Apr 16, 2023 · 2 comments
Open

Create primitiveStream methods for IntBag, LongBag and DoubleBag #1455

donraab opened this issue Apr 16, 2023 · 2 comments

Comments

@donraab
Copy link
Contributor

donraab commented Apr 16, 2023

Since 10.0, we have had primitiveStream on IntList, LongList and DoubleList. This makes the following possible:

List<String> list = IntLists.immutable.of(1, 2, 3)
        .primitiveStream()
        .mapToObj(Integer::toString)
        .toList();

Assertions.assertEquals(List.of("1", "2", "3"), list);

There is no equivalent for IntBag, LongBag, and DoubleBag today. This will additionally require creating spliterator() for each of these.

@Desislav-Petrov
Copy link
Contributor

hi @donraab - happy to take a look at this

@donraab
Copy link
Contributor Author

donraab commented Apr 19, 2023

Thanks for volunteering @Desislav-Petrov! I have assigned the issue to you.

Desislav-Petrov added a commit to Desislav-Petrov/eclipse-collections that referenced this issue May 12, 2023
Desislav-Petrov added a commit to Desislav-Petrov/eclipse-collections that referenced this issue May 12, 2023
Desislav-Petrov added a commit to Desislav-Petrov/eclipse-collections that referenced this issue May 13, 2023
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

2 participants