Great session in JavaOne 2017 about Streams and lambdas introduced in JDK8.
The session shows many examples of Java code using
forEach() with side effects and how to refactor them to a functional approach using streams and the Collectors API.
What are your experiences using Streams and lambdas in JDK 8? Are you correctly using the Collectors API?
My friends Andre and Leonnardo have sent me an interesting article about some bad habits every Java developer should stop doing in their code.
Basically the author picked up the following points and discussed each one of them, showing code examples why they aren’t good practices at all:
- Returning Null
- Defaulting to Functional Programming
- Creating Indiscriminate Getters and Setters
I agree with all these points as being bad practices in Java code. How about you? What do you think about it?