Skip to product information
Modern Java in Action
Modern Java in Action
Description
Book Introduction
The biggest change in the 18 years since Java 1.0 came out is Java 8.
With Modern Java since Java 8, you can use all your existing Java code as is, and you can also implement clearer and more concise code with new features, syntax, and design patterns.
This book introduces Java developers to key features added to Java 8, 9, and 10, including lambdas, streams, functional programming, the Java module system, parallelism and shared mutable data, and behavior parameterization, inspired by functional languages.
We will reward your efforts with crystal-clear examples and detailed information.
This book is a revised edition of Java 8 in Action, with chapters 1, 8, 10, 4, 17, and 21 being newly added or significantly revised.
All chapters except the appendix have been revised and supplemented.

index
About the translator and author
Translator's Note
Author's Note
About this book
Cover illustration introduction

[ PART I BASICS ]

CHAPTER 1 Java 8, 9, 10, 11: What's Going On?
1.1 What is the flow of history?
1.2 Why is Java still changing?
1.3 Java functions
1.4 Stream
1.5 Default Methods and Java Modules
1.6 Other useful ideas from functional programming
1.7 In conclusion

CHAPTER 2 Passing Behavior Parameterization Code
2.1 Responding to Changing Requirements
2.2 Motion parameterization
2.3 Simplifying complex processes
2.4 Practical Examples
2.5 In conclusion

CHAPTER 3 Lambda Expressions
3.1 What is Lambda?
3.2 Where and how to use lambda?
3.3 Using Lambda: The Run-Around Pattern
3.4 Using functional interfaces
3.5 Type checking, type inference, and constraints
3.6 Method Reference
3.7 Using Lambda and Method References
3.8 Useful methods for combining lambda expressions
3.9 Similar mathematical concepts
3.10 In conclusion

[ PART II Functional Data Processing ]

CHAPTER 4: Stream Introduction
4.1 What is a Stream?
4.2 Starting the Stream
4.3 Streams and Collections
4.4 Stream Operations
4.5 Roadmap
4.6 In conclusion

CHAPTER 5 Stream Utilization
5.1 Filtering
5.2 Stream Slicing
5.3 Mapping
5.4 Search and Matching
5.5 Reducing
5.6 Field Practice
5.7 Numeric Streams
5.8 Creating a Stream
5.9 In conclusion

CHAPTER 6 Collecting Data with Streams
6.1 What is a collector?
6.2 Reducing and Summarizing
6.3 Grouping
6.4 Split
6.5 Collector Interface
6.6 Improving Performance by Implementing a Custom Collector
6.7 In conclusion

CHAPTER 7 Parallel Data Processing and Performance
7.1 Parallel Streams
7.2 Fork/Join Framework
7.3 Spliterator Interface
7.4 In conclusion

[ PART III Effective Programming with Streams and Lambdas ]

CHAPTER 8 Collection API Improvements
8.1 Collection Factory
8.2 List and Set Handling
8.3 Map Processing
8.4 Improved ConcurrentHashMap
8.5 In conclusion

CHAPTER 9 Refactoring, Testing, and Debugging
9.1 Refactoring to improve readability and flexibility
9.2 Refactoring Object-Oriented Design Patterns with Lambdas
9.3 Lambda Testing
9.4 Debugging
9.5 In conclusion

CHAPTER 10 Domain-Specific Languages ​​Using Lambda
10.1 Domain-Specific Language
10.2 A small DSL for the latest Java API
10.3 Patterns and Techniques for Creating DSLs in Java
10.4 Real-Life Java 8 DSLs
10.5 In conclusion

[ PART IV Everyday with Java ]

CHAPTER 11 Optional Class Instead of Null
11.1 How to handle situations where there is no value?
11.2 Introducing the Optional Class
11.3 Optional Application Pattern
11.4 Practical Examples Using Optional
11.5 In conclusion

CHAPTER 12 NEW DATE AND TIME API
12.1 LocalDate, LocalTime, Instant, Duration, and Period classes
12.2 Date Adjustment, Parsing, and Formatting
12.3 How to use different time zones and calendars
12.4 In conclusion

CHAPTER 13 Default Methods
13.1 Changing APIs
13.2 What is a default method?
13.3 Default Method Utilization Patterns
13.4 Interpretation Rules
13.5 In conclusion

CHAPTER 14 The Java Module System
14.1 Pressure: Software Analogy
14.2 Why the Java Module System Was Designed
14.3 Java Modules: The Big Picture
14.4 Developing Applications with the Java Module System
14.5 Using Multiple Modules
14.6 Compiling and Packaging
14.7 Automatic Module
14.8 Module Definition and Syntax
14.9 Bigger Examples and More Ways to Learn
14.10 In conclusion

[ PART V Improved Java Concurrency ]

CHAPTER 15: CompletableFuture and the Basics of Reactive Programming Concepts
15.1 Evolution of Java Support for Concurrency
15.2 Synchronous and Asynchronous APIs
15.3 Box and Channel Models
15.4 Concurrency with CompletableFuture and Combinators
15.5 Publish-Subscribe and Reactive Programming
15.6 Reactive Systems vs. Reactive Programming
15.7 In conclusion

CHAPTER 16 CompletableFuture: Reliable Asynchronous Programming
16.1 Simple Uses of Future
16.2 Implementing Asynchronous APIs
16.3 Creating Non-Block Code
16.4 Creating an Asynchronous Work Pipeline
16.5 How to Respond to CompletableFuture Termination
16.6 Roadmap
16.7 In conclusion

CHAPTER 17 Reactive Programming
17.1 Reactive Manifesto
17.2 Reactive Streams and the Flow API
17.3 Using the reactive library RxJava
17.4 In conclusion

PART VI: Functional Programming and the Future of Java Evolution

CHAPTER 18 Thinking in a Functional Perspective
18.1 System Implementation and Maintenance
18.2 What is functional programming?
18.3 Recursion and Iteration
18.4 In conclusion

CHAPTER 19 FUNCTIONAL PROGRAMMING TECHNIQUES
19.1 Functions are everywhere
19.2 Persistent Data Structures
19.3 Streams and Lazy Evaluation
19.4 Pattern Matching
19.5 Other Information
19.6 In conclusion

CHAPTER 20 Harmonizing OOP and FP: Comparing Java and Scala
20.1 Introduction to Scala
20.2 Functions
20.3 Classes and Traits
20.4 In conclusion

CHAPTER 21 Conclusion and the Future of Java
21.1 Java 8 Feature Review
21.2 Java 9 Module System
21.3 Java 10 Local Variable Type Inference
21.4 The Future of Java
21.5 Java Evolves Faster
21.6 Conclusion

supplement
_APPENDIX A Other Language Updates
_APPENDIX B Other Library Updates
_APPENDIX Executing Multiple Operations in Parallel on a C Stream
_APPENDIX D Lambdas and JVM Bytecode

Detailed image
Detailed Image 1

Publisher's Review
Learn the all-new features of Java 8, 9, and 10 in a refreshing way!

This book shows you how to practically apply the latest Java features to your applications.
We will reward your efforts with crystal-clear examples and detailed information.
You'll also learn how to leverage your existing knowledge of core Java, as well as modern additions like the Streams API, the Java module system, new approaches to concurrency, and functional concepts, to help you implement readable and maintainable code.

Why should I use this new feature?

For example, among the newly added features, lambda allows for more concise Java programs to be implemented.
Most readers will have already had experience registering objects containing methods to be called when an event occurs, using event handlers, callbacks, etc.
Lambda allows this feature to be used in a wider range of fields.
In other words, you can simply pass code or methods that can be executed during some operation as arguments using lambda and its friend, method reference.
Ultimately, you'll find that this functionality is used more often than you might expect—from parameterizing methods in code to complex queries that ingest data using the new Streams API.

Structure of this book

This book is largely composed of six sections: 'Basics', 'Functional Data Processing', 'Effective Programming with Streams and Lambdas', 'Everyday Java', 'Improved Java Concurrency', and 'Functional Programming and the Future of Java Evolution'.
The chapters introduced in Parts 1 and 2 should be read in order to understand the context, but the remaining four parts are independent and can be read in any order.
Most chapters include a variety of quizzes to help you practice.

_Part 1: Provides three chapters covering content suitable for readers who are new to Java 8.
By the end of Part 1, you'll understand what lambda expressions are and be able to use them to write concise, flexible code that can easily adapt to changing requirements.

_Part 2: Detailing the new stream API.
By the end of Part 2, you'll know what streams are and how to use them to implement concise, efficient applications that process collections of data.

_Part 3: We will look at various Java 8 and Java 9 related contents that will help you use Java more effectively and improve your code with the latest techniques.
Because the goal is to explain the most up-to-date programming concepts possible, other parts of this book do not utilize material covered in Part 3.

_Part 4: We'll look at various new features added to Java 8 and Java 9 to make it easier and more reliable to write code that composes your projects.

_Part 5: We will go beyond the easy parallel processing methods using streams described in Chapters 6 and 7 and look at advanced techniques for structuring parallel programming in Java.

_Part 6: Let's switch gears a bit and compare the features of Scala and Java 8 to see how to effectively implement functional programming in Java.

_Appendix: Appendix A summarizes minor features of the Java 8 language that were not covered in the book.
Appendix B describes features added to the Java library that may be useful.
Appendix C is an extension of Part 2 and describes advanced usage of streams.
Appendix D explains the details of how the Java compiler implements lambda expressions.

Contents of this book

- How to use the powerful new features of Java 8, Java 9, and Java 10
- How to implement applications that effectively utilize multicore
- Refactoring, testing, debugging
- Application of functional programming
- Appendix containing quizzes, surprise questions, and updates
GOODS SPECIFICS
- Date of issue: August 1, 2019
- Page count, weight, size: 692 pages | 926g | 183*235*35mm
- ISBN13: 9791162242025
- ISBN10: 1162242027

You may also like

카테고리