What's New in Java 8
Free!
With Membership
$15.00
Suggested price

What's New in Java 8

An unofficial guide to Java and JDK 1.8

About the Book

If you're just getting to Java 8, I definitely recommend@adamldavis' book -- very concise and helpful. -Fred Jonsson

Java 8 is a giant step forward for the Java language. In Project Lambda, Java gets a new closure syntax (lambda expressions), method-references, and default and static methods on interfaces. It manages to add many of the features of functional languages without losing the clarity and simplicity Java developers have come to expect. In addition, many of the existing Java core library classes have been enhanced with the new Streams API.

This ebook will help you understand Java 8, including: Project Lambda, the new Date-Time API, Streams, default methods, Nashorn, and more.

This book is 100% complete and available in print here and other places.

If you like this, please check out Adam's other books: Learning Groovy, Modern Java Second Edition, and Modern Programming Made Easy

10% of all proceeds go directly to the Electronic Frontier Foundation (EFF).

DisclaimerJava is a registered trademark of Oracle. You can find Java here on Oracle's website.

About the Author

Adam L. Davis
Adam L. Davis

Adam Davis makes software. He's spent many years developing in Java (since Java 1.2) and has enjoyed using Spring, Hibernate, Grails, and many others. He has used Java, Groovy, JavaScript, AWS, and much more to build applications for over a decade and has worked at both large and small corporations. Adam is a Certified Spring Professional and has a Masters and a Bachelors degree in Computer Science from Georgia Tech.

http://adamldavis.com

Bundles that include this book

$40.00
Bought separately
$11.95
Bundle Price
$54.00
Bought separately
$23.99
Bundle Price
$55.00
Bought separately
$25.00
Bundle Price

Table of Contents

  • Preface
  • 1. Overview
  • 2. Lambda Expressions
    • 2.1 Syntax
    • 2.2 Scope
    • 2.3 Method references
    • 2.4 Functional Interfaces
    • 2.5 Comparisons to Java 7
  • 3. Default Methods
    • 3.1 Default and Functional
    • 3.2 Multiple Defaults
    • 3.3 Static Methods on Interface
  • 4. Streams
    • 4.1 What is a Stream?
    • 4.2 Generating Streams
    • 4.3 For Each
    • 4.4 Map/Filter/Reduce
    • 4.5 Parallel Array
    • 4.6 Peek
    • 4.7 Limit
    • 4.8 Sort
    • 4.9 Collectors and Statistics
    • 4.10 Grouping and Partitioning
    • 4.11 Comparisons to Java 7
  • 5. Optional
  • 6. Nashorn
    • 6.1 jjs
    • 6.2 Scripting
    • 6.3 ScriptEngine
    • 6.4 Importing
    • 6.5 Extending
    • 6.6 Invocable
  • 7. New Date and Time API
    • 7.1 New Classes
    • 7.2 Creation
    • 7.3 Enums
    • 7.4 Clock
    • 7.5 Period and Duration
    • 7.6 Temporal Adjusters
    • 7.7 Instant
    • 7.8 Time Zones
    • 7.9 Backwards Compatibility
  • 8. No More Permanent Generation
  • 9. Miscellaneous
    • 9.1 Base64
    • 9.2 CompletableFuture
    • 9.3 Annotations on Java Types
    • 9.4 Repeating Annotations
  • 10. Functional Programming in Java 8
    • 10.1 Functions
    • 10.2 Immutability
    • 10.3 Concurrency
    • 10.4 Tail-Call Optimization
  • 11. Conclusion
  • Backports
  • Contact the Author
  • Notes

Causes Supported

Electronic Frontier Foundation

Defending your civil liberties in a digital world.
https://www.eff.org/

Based in San Francisco, EFF is a donor-supported membership organization working to protect fundamental rights regardless of technology.

From the Internet to the iPod, technologies are transforming our society and empowering us as speakers, citizens, creators, and consumers. When our freedoms in the networked world come under attack, the Electronic Frontier Foundation (EFF) is the first line of defense. EFF broke new ground when it was founded in 1990—well before the Internet was on most people's radar—and continues to confront cutting-edge issues defending free speech, privacy, innovation, and consumer rights today. From the beginning, EFF has championed the public interest in every critical battle affecting digital rights.

The Leanpub 60 Day 100% Happiness Guarantee

Within 60 days of purchase you can get a 100% refund on any Leanpub purchase, in two clicks.

Now, this is technically risky for us, since you'll have the book or course files either way. But we're so confident in our products and services, and in our authors and readers, that we're happy to offer a full money back guarantee for everything we sell.

You can only find out how good something is by trying it, and because of our 100% money back guarantee there's literally no risk to do so!

So, there's no reason not to click the Add to Cart button, is there?

See full terms...

80% Royalties. Earn $16 on a $20 book.

We pay 80% royalties. That's not a typo: you earn $16 on a $20 sale. If we sell 5000 non-refunded copies of your book or course for $20, you'll earn $80,000.

(Yes, some authors have already earned much more than that on Leanpub.)

In fact, authors have earnedover $13 millionwriting, publishing and selling on Leanpub.

Learn more about writing on Leanpub

Free Updates. DRM Free.

If you buy a Leanpub book, you get free updates for as long as the author updates the book! Many authors use Leanpub to publish their books in-progress, while they are writing them. All readers get free updates, regardless of when they bought the book or how much they paid (including free).

Most Leanpub books are available in PDF (for computers) and EPUB (for phones, tablets and Kindle). The formats that a book includes are shown at the top right corner of this page.

Finally, Leanpub books don't have any DRM copy-protection nonsense, so you can easily read them on any supported device.

Learn more about Leanpub's ebook formats and where to read them

Write and Publish on Leanpub

You can use Leanpub to easily write, publish and sell in-progress and completed ebooks and online courses!

Leanpub is a powerful platform for serious authors, combining a simple, elegant writing and publishing workflow with a store focused on selling in-progress ebooks.

Leanpub is a magical typewriter for authors: just write in plain text, and to publish your ebook, just click a button. (Or, if you are producing your ebook your own way, you can even upload your own PDF and/or EPUB files and then publish with one click!) It really is that easy.

Learn more about writing on Leanpub