A Functional Approach to Java: Augmenting Object-Oriented Java Code with Functional Principles
暫譯: 功能性方法的Java:用功能原則增強物件導向的Java程式碼

Weidig, Ben

  • 出版商: O'Reilly
  • 出版日期: 2023-06-13
  • 定價: $2,600
  • 售價: 8.8$2,288
  • 語言: 英文
  • 頁數: 403
  • 裝訂: Quality Paper - also called trade paper
  • ISBN: 1098109929
  • ISBN-13: 9781098109929
  • 相關分類: Java 程式語言Object-oriented
  • 立即出貨 (庫存 < 3)

買這商品的人也買了...

相關主題

商品描述

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.

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.

商品描述(中文翻譯)

Java 開發者通常透過物件導向程式設計 (OOP) 來應對軟體開發的複雜性。但並非每個問題都適合使用 OOP。函數式程式設計 (FP) 範式為您提供了另一種解決問題的方法,而 Java 提供了易於理解的 FP 工具,例如 lambdas 和 streams。如果您有興趣將 FP 概念應用於您的 Java 代碼,這本書就是為您而寫。

作者 Ben Weidig 突出了函數式程式設計的不同方面,並向您展示如何在不完全轉向「完全函數式」的情況下將它們融入您的代碼中。您將學習如何、何時以及為什麼使用 FP 概念,例如不可變性和純函數,以編寫更簡潔、合理且未來可擴展的代碼。許多開發者希望通過同時使用 OOP 和 FP 來擴展他們的視野。這不再是二選一,而是兩者兼具。

本書分為兩個部分,包括:
- **函數式方法:** 獲得函數式程式設計的高層次概述,包括已經可供 Java 開發者使用的類型。然後探索不同的 FP 概念並學習如何使用它們。
- **現實世界的問題、模式和範例:** 將您在第一部分學到的知識應用於您在日常工作中可能遇到的典型現實世界問題。