Java 8: How to Read a File As a Stream

When, in the course of human events, it becomes necessary to read a text file, you should consider usingĀ a Stream. Why? Because a Stream gives you the opportunity to perform some on-the-fly operations that go beyond simple traversal. In this article, we’ll look at how you can use a Stream (with some other Java 8…

Java 8: How to Use forEach With Lambda Expressions

Looping is certainly not new to Java 8, but you can tighten up your code quite a bit with the forEach expression. And cleaner code is better, right? In this article, we’ll go over how to use forEach in your code as a substitute for one of the old for expressions. As is usually the…

Java 8: How to Use Comparators With Lambda Expressions

If you’re using Java 8 (or higher), you really should take advantage of lambda expressions in your sorting logic. Why? Because it’s a great way to tighten your code and make it easier to read. In this article we’ll go over how to use the Comparator interface with lambda expressions. As is usually the case,…

Hot to Implement AJAX With Spring Boot

Modern web application development is (almost) all about offering the user a rich experience. That’s why AJAX is so popular. In case you’re unfamiliar with the acronym, AJAX stands for Asynchronous JavaScript and XML. It’s usually used to refresh just a part of a web page without forcing the user to reload the entire page.…