Use this tag for questions specific to Java 8 which is version 8 (internal number 1.8) of the Java platform, released on 18 March 2014.
I am trying to change some for-each loops to lambda forEach()-methods to discover the possibilities of lambda expressions. The …
java foreach lambda java-8 return-typeI have a collection of BigDecimals (in this example, a LinkedList) that I would like to add together. Is it …
java bigdecimal java-8 java-streamIDEA has a great built-in feature - decompiler. It works great.I can copy source code, but I cannot find …
java intellij-idea java-8 decompilingI found the code for grouping the objects by some field name from POJO. Below is the code for that: …
java java-8I have a question regarding the usage of the Function.identity() method. Imagine the following code: Arrays.asList("a", "b", "…
java lambda java-8 java-streamHow to get first element that matches a criteria in a stream? I've tried this but doesn't work this.stops.…
java java-8 java-streamI am simply trying to convert a date string into a DateTime object in Java 8. Upon running the following lines: …
java datetime java-8 datetime-formatI want to replace the following code using java8 Optional: public Obj getObjectFromDB() { Obj obj = dao.find(); if (obj != null) { …
java java-8 optionalI am trying to understand the difference between the Optional<T>.orElse() and Optional<T>.orElseGet() …
java java-8 optionalWhen using the Java 8 Optional class, there are two ways in which a value can be wrapped in an optional. …
java java-8 nullpointerexception null optional