LitMy.ru - литература в один клик

A Functional Approach to Java (Final Release)

  • Добавил: literator
  • Дата: 10-05-2023, 05:01
  • Комментариев: 0
A Functional Approach to Java (Final Release)Название: A Functional Approach to Java: Augmenting Object-Oriented Code with Functional Principles (Final Release)
Автор: Ben Weidig
Издательство: O’Reilly Media
Год: 2023
Страниц: 403
Язык: английский
Формат: epub, mobi
Размер: 10.2 MB

Java developers usually tackle the complexity of software development through object-oriented programming (OOP). But not every problem is a good match for OOP. The functional programming (FP) paradigm offers you another approach to solving problems, and Java provides easy-to-grasp FP tools such as lambdas and streams. If you're interested in applying FP concepts to your Java code, this book is for you.

Author Ben Weidig highlights different aspects of functional programming and shows you how to incorporate them in your code without going "fully functional." You'll learn how, when, and why to use FP concepts such as immutability and pure functions to write more concise, reasonable, and future-proof code. Many developers seek to expand their horizons by using OOP and FP together. It's no longer either-or; it's both.

Developing software is quite a complex endeavor. As Java developers, we usually try to tame this complexity with object-oriented programming (OOP) as a metaphor to represent the things we are developing, such as data structures, and use a primarily imperative-focused coding style to handle our program’s state. Although OOP is a well-known and battle-tested approach to developing sensible software, not every problem is a good match for it. We might introduce a certain amount of unnecessary complexity by forcing OOP principles on every problem instead of using more appropriate tools and paradigms also available to us. The functional programming (FP) paradigm offers an alternative approach to solving problems.

Functional programming isn’t a new idea. In fact, it’s even older than object-oriented programming! It first appeared in the early years of computing, in the 1950s, in the Lisp⁠ programming language and has been used quite commonly in academia and niche fields. In recent years, however, there has been an increasing interest in functional paradigms.

Many new functional languages have emerged, and non-functional languages are including functional features to various degrees. The ideas and concepts behind FP are now adopted in almost every mainstream multiparadigm and general-purpose language, allowing us to use some form of functional programming regardless of the context and chosen language. Nothing stops us from taking the best parts of FP and augmenting our existing way of programming and software development tools— and that’s what this book is about!

In two parts, this book includes:
A Functional Approach: Get a high-level overview of functional programming, including the types already available to Java developers. Then explore different FP concepts and learn how to use them.
Real-World Problems, Patterns, and Recipes: Apply what you've learned in part one to the typical real-world problems you might encounter in your daily work.

Who Should Read This Book:
This book is for you if you are curious about functional programming and want to know what all the fuss is about and apply it to your Java code. You might already be using some functional Java types but desire a more profound knowledge of why and how to apply them more effectively. There is no need to be an expert on OOP, but the book is not a beginner’s guide to Java or OOP. You should already be familiar with the Java standard library. No prior knowledge of functional programming is required. Every concept is introduced with an explanation and examples. The book covers Java 17 as the latest Long-Term-Support (LTS) version available at publication. But knowing that many developers need to support projects with earlier versions, the baseline will be the previous LTS, Java 11.

This book might not be for you if you are looking for a compartmentalized, recipe-style book presenting “ready-to-implement” solutions. Its main intention is to introduce functional concepts and idioms and teach you how to incorporate them into your Java code.

Скачать A Functional Approach to Java (Final Release)












[related-news] [/related-news]
Внимание
Уважаемый посетитель, Вы зашли на сайт как незарегистрированный пользователь.
Мы рекомендуем Вам зарегистрироваться либо войти на сайт под своим именем.