Custom Thread Pools In Java 8 Parallel Streams (#1088)
* String to char array and char array to String. * Method change * Custom ThreadPool In Java 8 Parallel Streams * Implemented suggested edits from editor. * Broke long method signature * Changed primitive type int to long and formula. * Update wrapper type to Long
This commit is contained in:
parent
c350e8b423
commit
a1312e9ce0
@ -21,7 +21,7 @@ public class ThreadPoolInParallelStream {
|
||||
long firstNum = 1;
|
||||
long lastNum = 1_000_000;
|
||||
|
||||
List<Long> aList = LongStream.range(firstNum, lastNum).boxed()
|
||||
List<Long> aList = LongStream.rangeClosed(firstNum, lastNum).boxed()
|
||||
.collect(Collectors.toList());
|
||||
|
||||
ForkJoinPool customThreadPool = new ForkJoinPool(4);
|
||||
|
Loading…
x
Reference in New Issue
Block a user