-
Java 8 Convert List to Map
Few Java 8 examples to show you how to convert a List of objects into a Map, and how to handle the duplicated keys.
Date: 2019-08-17 View: 1520
-
Java 8 Convert a Stream to List
A Java 8 example to show you how to convert a Stream to a List via Collectors.toList
Date: 2019-08-17 View: 1520
-
Java Display all ZoneId and its UTC offset
A Java 8 example to display all the ZoneId and its OffSet hours and minutes.
Date: 2019-08-17 View: 1520
-
Java Convert comma-separated String to a List
Java examples to show you how to convert a comma-separated String into a List and vice versa.
Date: 2019-08-11 View: 1520
-
How to tell Maven to use Java 8
In pom.xml, defined this maven.compiler.source properties to tell Maven to use Java 8 to compile the project.
Date: 2019-08-11 View: 1520
-
Java How to join List String with commas
In Java, we can use String.join(",", list) to join a List String with commas.
Date: 2019-08-11 View: 1520
-
Java 8 Stream.iterate examples
In Java 8, we can use Stream.iterate to create stream values on demand, so called infinite stream.
Date: 2019-08-11 View: 1520
-
Java Fibonacci examples
Fibonacci number – Every number after the first two is the sum of the two preceding.
Date: 2019-08-11 View: 1520
-
Java 8 How to sort list with stream.sorted()
Few examples to show you how to sort a List with stream.sorted()
Date: 2019-08-11 View: 1520
-
Java 8 How to convert IntStream to Integer[]
The key is boxed() the IntStream into a Stream<Integer>, then only convert to an Array.
Date: 2019-08-11 View: 1520
-
Java 8 Convert a Stream to Array
In Java 8, we can use .toArray() to convert a Stream into an Array.
Date: 2019-08-11 View: 1520
-
java.lang.UnsupportedClassVersionError
Start a Java class and hits this java.lang.UnsupportedClassVersionError, what is class file version 52 56?
Date: 2019-08-11 View: 1520
-
Java Convert ArrayList<String> to String[]
In the old days, we can use list.toArray(new String[0]) to convert a ArrayList<String> into a String[]
Date: 2019-08-11 View: 1520
-
Java How to check if a String is numeric
Few Java examples to show you how to check if a String is numeric.
Date: 2019-08-11 View: 1520
-
Java Convert Array to ArrayList
In Java, we can use new ArrayList<>(Arrays.asList(array)) to convert an Array into an ArrayList
Date: 2019-08-11 View: 1520