
The “final” Keyword in Java
1. Overview While inheritance enables us to reuse existing code, sometimes we do need to set limitations on extensibility for various reasons; the final keyword allows us to do […]
1. Overview While inheritance enables us to reuse existing code, sometimes we do need to set limitations on extensibility for various reasons; the final keyword allows us to do […]
1. Introduction Regular expressions are a powerful tool for matching various kinds of patterns when used appropriately. In this article, we’ll use java.util.regex package to determine whether […]
1. Overview In this quick tutorial, we’re going to take a look at two new classes for working with dates introduced in Java 8: Period and Duration. Both […]
1. Introduction When dealing with exceptions in Java, we’re frequently logging or simply displaying stack traces. However, sometimes, we don’t want just to print the […]
1. Overview StackOverflowError can be annoying for Java developers, as it’s one of the most common runtime errors we can encounter. In this article, we’ll see […]
1. Overview Enum in Java is a datatype that helps us assign a predefined set of constants to a variable. In this quick article, we’ll see […]
1. Introduction Both ClassNotFoundException and NoClassDefFoundError occur when the JVM can not find a requested class on the classpath. Although they look familiar, there are some core differences between […]
1. Overview The java.io.File class has three methods — getPath(), getAbsolutePath() and getCanonicalPath() — to obtain the filesystem path. In this article, we’ll have a quick look at the differences between them […]
1. Overview UUID (Universally Unique Identifier), also known as GUID (Globally Unique Identifier) represents a 128-bit long value that is unique for all practical purposes. The standard representation […]
1. Overview In this short tutorial, we’ll learn how to round a number to n decimal places in Java. 2. Decimal Numbers in Java Java provides two […]
1. Timer – the Basics Timer and TimerTask are java util classes used to schedule tasks in a background thread. In a few words – TimerTask is the task to […]
1. Generate an Unbounded Long Let’s start with generating a Long: 2. Generate a Long Within a Range 2.1. Random Long With Plain Java Next […]
1. Overview In this tutorial, we’re going to take a first look at the Lambda support in Java 8 – specifically at how to leverage it […]
1. Introduction The binary number system uses 0s and 1s to represent numbers. Computers use binary numbers to store and perform operations on any data. […]
1. Introduction Comparing objects is an essential feature of object-oriented programming languages. In this tutorial, we’re going look at some of the features of the […]
1. Introduction In Java’s if-else statements we can take a certain action when an expression is true, and an alternative when it is false. In this tutorial, we’ll learn […]
1. Overview In this short tutorial, we’ll investigate the definition of “Plain Old Java Object” or POJO for short. We’ll look at how a POJO compares to […]
1. Overview In the most basic sense, a program is a list of instructions. Control structures are programming blocks that can change the path we take […]
1. Introduction In this quick guide, we’ll discuss the term “concrete class” in Java. First, we’ll define the term. Then, we’ll see how it’s different from […]
1. Overview In this tutorial, we’ll focus on a core aspect of the Java language – the finalize method provided by the root Object class. Simply put, this is […]