Home » Tag Archives: Java 8 (page 11)

Tag Archives: Java 8

Dubious Aspects of Features of JDK 8

java-logo

Most of us who develop with Java are generally enthusiastic for the features and improvements that come with JDK 8. However, there have been several recent posts that have pointed out some features that can be misused and abused and might lead to some additional issues in the future. These features, which remind me of the introduction of autoboxing in ...

Read More »

How much faster is Java 8?

java-logo

Java SE 8 was released yesterday. Traditionally, every new major JRE version comes with a free performance boost. Do we get another free lunch? And how big is the gain this time? Let’s benchmark it.             Benchmark methodology Run the same code with 3 different JRE versions (SunJDK 1.6.0_26, OpenJDK 1.7.0_51 and OpenJDK 1.8.0). The ...

Read More »

Constructor/Method Parameters Metadata Available Via Reflection in JDK 8

java-logo

One of the lesser advertised new features of JDK 8 is the optional ability to include parameter metadata in compiled Java classes [JDK Enhancement Proposal (JEP) 118]. This feature allows Java applications to access this parameter metadata information at runtime via reflection. The Java Tutorials‘ Reflection API trail includes a lesson called Obtaining Names of Method Parameters that discusses and ...

Read More »

New Parallelism APIs in Java 8: Behind The Glitz and Glamour

java-logo

I’m a great multi-tasker. Even as I’m writing this post, I can still find room to feel awkward about a remark I made yesterday at a party that had everyone looking at me strange. Well, the good news is I’m not alone – Java 8 is also pretty good at multi-tasking. Let’s see how. One of the key new features ...

Read More »

Java 8 Friday: The Dark Side of Java 8

java-logo

At Data Geekery, we love Java. And as we’re really into jOOQ’s fluent API and query DSL, we’re absolutely thrilled about what Java 8 will bring to our ecosystem. Java 8 Friday Every Friday, we’re showing you a couple of nice new tutorial-style Java 8 features, which take advantage of lambda expressions, extension methods, and other great stuff. You’ll find ...

Read More »

Creating your own loop structure in Java 8 lambda

java-logo

Java doesn’t have an easy construct of repeat something N number of times. We can make a for loop of course, but many times we don’t even care about the variable that we created in the loop. We just want repeat N times of some code and that’s it. With the lambda available in Java 8, you may attempt something ...

Read More »

How not to use Java 8 default methods

java-logo

Warning: you can not make this unseen once you have read I was talking about the multiple inheritance of default methods in the last blog article and how they behave during compilation and run time. This week I look at how to use default methods to do real inheritance, which actually, default methods were not designed for. For this very ...

Read More »

Java 8 default methods: what can and can not do?

java-logo

What default method is With the release of Java 8 you can modify interfaces adding new methods so that the interface remains compatible with the classes that implement the interface. This is very important in case you develop a library that is going to be used by several programmers from Kiev to New York. Until the dawn of Java 8 ...

Read More »

How to process stream and read text file in Java 8

java-logo

I have converted one of my old utility class using latest Java8. I use this often to print content of manifest file to check any mysterious jar file for version etc. Just run “java ztools.PrintJar /path/to/my.jar” to see output. In the new code, you will see how I use the Java 8 stream processing to filter what I need from ...

Read More »

Java 8 Date Time API Tutorial : LocalDateTime

java-logo

This blogpost is a part of tutorial series on Date Time API introduced in Java 8. In this blogpost I will go over some of the methods available in LocalDateTime class. LocalDateTime is an immutable, thread safe object which represents date-time without a time-zone in the ISO-8601 calendar system, such as 2014-03-30T02:51:21. It is normally represented in year-month-day-hour-minute-second and provides accuracy ...

Read More »
Want to take your Java Skills to the next level?
Grab our programming books for FREE!
  • Save time by leveraging our field-tested solutions to common problems.
  • The books cover a wide range of topics, from JPA and JUnit, to JMeter and Android.
  • Each book comes as a standalone guide (with source code provided), so that you use it as reference.
Last Step ...

Where should we send the free eBooks?

Good Work!
To download the books, please verify your email address by following the instructions found on the email we just sent you.