There are many ways to create a stream (a Stream object). In this post we just list a few the most popular methods.
Articles related to : feature
Java streams 2. API overview
April 24, 2019 Java programming
There are four interfaces that can represent a stream of data: Stream, IntStream, LongStream, or DoubleStream – all in the package java.util.stream since Java 8
Lambda expressions 1. Basics
April 13, 2019 Java programming
Lambda expression allows simplifying an interface implementation, but only in the case of an interface with one abstract method only (called a functional interface). Instead of creating a class that implements the interface (and pass its object as a parameter), a lambda expression allows to to pass in only the method body, without creating an […]
Method equals() is the correct way to compare String objects
August 1, 2018 Java programming
Method equals() compares objects by reference and by value. In the case of literals, comparison by reference is enough. Which means that method equals() as fast while comparing literals as the reference comparison.