Closed mizhoux closed 10 months ago
Hello!
In this case, you don't need zip
. It's better to use mapToEntry
StreamEx.of(userIds).mapToEntry(id -> config)
This is essentially not a zipping, it's a plain mapping of a single element to a pair.
Wow, thanks for helping me find the method.
Currently, if we want to zip keys with a single value to get an
EntryStream
, we need to do this:If
EntryStream
had a factory method like this:Then it's much easier (and efficient) to use: