Category Java

Reactive HTTP Client With Spring 5 WebClient

This article is going to cover about Spring 5 WebClient, a non-blocking, reactive client for HTTP requests with Reactive Streams back pressure. 1. Introduction To Spring 5 WebClient The WebClient is a non-blocking, reactive HTTP client which has been introduced… Continue Reading →

Java 9 – Effectively Final Variables In try-with-resources

In this tutorial, we’re going to get through how to use effectively final variables in the try-with-resources statement in Java 9. 1. The try-with-resources Statement In Java The try-with-resources statement is a try statement that declares one or more resource… Continue Reading →

Java 9 HTTP/2 Client API Example

1. Overview This tutorial is going to cover Java 9 HTTP/2 Client API. We’ll get through how to create a HttpClient object, make HTTP requests and handle HTTP Responses. Notice that the HTTP/2 Client API is an incubator module named… Continue Reading →

How To Compare Arrays In Java 9

In this tutorial, we’re going to get through new methods that have been added to the java.util.Arrays class since Java 9, which enables us to compare arrays and slices of arrays in Java efficiently. 1. Compare Arrays Equality In Java 9… Continue Reading →

Streams API Updates In Java 9

In this tutorial, we’re going to take a first look at the streams API updates in Java 9, which includes new stream operations: dropWhile, takeWhile, iterate and ofNullable. 1. The dropWhile() Method Firstly, let’s take a look at the syntax… Continue Reading →

Java 9 – New Methods Of The Optional Class

This tutorial is going to cover about new methods of the Optional<T> class in Java 9. We’re going to get through 3 methods which recently added, have the syntax as follows: void ifPresentOrElse(Consumer<? super T> action, Runnable emptyAction) Optional<T> or(Supplier<?… Continue Reading →

Java 9 JShell Cheat Sheet

This tutorial is going provide a quick reference for commands that will frequently encounter when we work with JShell in Java 9. Hopefully, this will be a useful Java 9 JShell cheat sheet. 1. What Is JShell The JShell tool… Continue Reading →

Copy Streams In Java 9 With The InputStream.transferTo() Method

1. Overview This quick tutorial is going to cover how to use the InputStream.transferTo(), a new method that has been added to the InputStream class from Java 9,  to copy data from input streams to output streams in Java. 2…. Continue Reading →

Private Interface Methods In Java 9

This quick tutorial is going to cover about private interface methods in Java 9. 1. Overview As you may know, from Java 8, interfaces can have default methods which enable us to add new functionality to the interfaces of our libraries… Continue Reading →

Set Up Eclipse, IntelliJ And NetBeans For Java 9

This tutorial is going to cover how to set up Eclipse, IntelliJ and NetBeans for Java 9 which has been released. 1. Prerequisites Java 9 is installed in your environment. You can download it from the official website or follow… Continue Reading →

« Older posts Newer posts »

© 2020 HowToProgram — Powered by WordPress

Theme by Anders NorenUp ↑

NewsletterSubscribe To Learn More