MCPcopy Index your code
hub / github.com/BruceEckel/OnJava8-Examples / main

Method main

generics/ListOfInt.java:11–16  ·  view source on GitHub ↗
(String[] args)

Source from the content-addressed store, hash-verified

9
10public class ListOfInt {
11 public static void main(String[] args) {
12 List<Integer> li = IntStream.range(38, 48)
13 .boxed() // Converts ints to Integers
14 .collect(Collectors.toList());
15 System.out.println(li);
16 }
17}
18/* Output:
19[38, 39, 40, 41, 42, 43, 44, 45, 46, 47]

Callers

nothing calls this directly

Calls 2

boxedMethod · 0.80
rangeMethod · 0.80

Tested by

no test coverage detected