Refactoring to Java 8 Streams and Lambdas
Разное | Автор: LeeAndro | Добавлено: 16-10-2020, 05:34 | Просмотров (11) | Комментариев (0) | Жалоба |
Refactoring to Java 8 Streams and Lambdas
MP4 | Video: h264, 1920x1080 | Audio: AAC, 44.1 KHz, 2 Ch
Genre: eLearning | Language: English | Duration: 62 Lessons (4h 47m) | Size: 9.45 GB

Java celebrated its 25th birthday in 2020.

Code written in 1995 stilll runs today, without even having to recompile it. This is one of the biggest reasons why Java has had such success in enterprises.

Over the years, we have seen lots of improvements to make Java code easier to work with. Inner classes came in Java 1.1. A proper collection framework joined us in Java 1.2. Java 5 gave us better type safety with generics.

But the biggest improvement for Java programmers came in Java 8 with Streams and Lambdas. We can now write Java code in the declarative style, rather than imperative. This expresses better the "what", rather than the "how" of the program logic.

Since Java 8, we have had a constant stream of improvements to the Java Programming Language. Records, sealed classes, pattern matching, local variable type inference, and many more. They all serve to make it easier to craft great Java code.

Unfortunately a lot of Java code bases are still stuck in the dark ages of Java 6. This needs refactoring.

In this one-day course we learn how and when to "refactor", focusing on the biggest improvement: Java Streams. However, we also show what else is new in the Java Programming Language.

This is a very hands-on course. Each section has exercises where we get to refactor an existing code base of a large ERP system with 330k LOC.

How to refactor to streams and lambdas with and without IDE assistance

The place of streams and lambdas in the history of the JDK

What is a functional interface?

The four core functional interface types found in the java.util.function package

How the lambda notation is a shorthand for an anonymous inner class based on a functional interface

The long and short forms that lambdas can take depending on their complexity

Method references as a further simplification of certain forms of lambda

How default and static methods in interfaces can use lambdas to improve generality, correctness and readability

When it might be unsafe to use methods like Map.computeIfAbsent

The concept of a stream and its relationship to iterable collections

Why coding with streams follows the algorithm logic more naturally than using for/while loops

How to create, transform and teate streams using filters, mappings, matchers, collectors, reducers, etc

Why we should use collectors rather than forEach to build collections from a stream

Using the Optional class to avoid null checks, and how optionals are used with streams

How to handle exceptions in lambdas using sneaky throws (without Lombok)

How functional interfaces, streams and optionals are optimized for the primitive types int, long and double



Уважаемый посетитель, Вы зашли на сайт как незарегистрированный пользователь. Мы рекомендуем Вам зарегистрироваться либо войти на сайт под своим именем.
  • 0
Похожие новости:
Посетители, находящиеся в группе Гости, не могут оставлять комментарии к данной публикации.
Панель управления
На сайте
Пользователей Юзеры (0)
Гостей Гости (37)
Роботов Боты (3)
crawl Botbotbot
Всего Всего на сайте (40)
Не попавшее на главную
Архивы сайта