Home » Author Archives: Ilias Koutsakis

Author Archives: Ilias Koutsakis

Ilias Koutsakis
Ilias has graduated from the Department of Informatics and Telecommunications of the National and Kapodistrian University of Athens. He is interested in all aspects of software engineering, particularly data mining, and loves the challenge of working with new technologies. He is pursuing the dream of clean and readable code on a daily basis.

org.apache.commons.io.FileUtils Example

In this example we are going to show some of the capabilities of the FileUtils class, which is a part of Apache Commons IO. The methods implemented in this class are all about file manipulation, and in many cases they make a developer’s life much easier. The main reason that this and other classes in Apache Commons exist, is that ...

Read More »

java.util.concurrent.LinkedBlockingQueue Example

In this example we are going to explain the use of the LinkedBlockingQueue class, and how it is different from the similar ArrayBlockingQueue. The main point of similarity is the concurrent capabilities of both classes, which makes sense as both are part of the java.util.concurrent package. Although they are the most common implementations of the BlockingQueue interface, certain differences need to ...

Read More »

java.util.concurrent.ArrayBlockingQueue Example

In this post we are going to present the ArrayBlockingQueue class, which implements the BlockingQueue interface. The main reason to use the ArrayBlockingQueue class is that it is thread-safe, in the sense that it can be used concurrently between different threads without any risk. Moreover, it has a specific capacity limit, which can be used in our advantage, e.g. when we ...

Read More »

java.net.MulticastSocket Example

In this example we are going to explain how to use MulticastSocket in Java, in order to enable a server to easily send information to multiple clients, which are all connected to the same port and address. We will describe the whole process, by creating both the server and the client, and guide you through the main concepts that need to be understood to ...

Read More »

java.util.Deque – Deque Java Example

In this example, we are going to explain the java.util.Deque Deque Java interface. The interface name is an abbreviation of “Double Ended Queue”, and it is essentially a queue that implements methods which allows the developer to add elements to both ends of the queue (head and tail). We are going to show the most important methods of this interface, ...

Read More »

java.net.NetworkInterface Example

In this example we are going to examine the java.net.NetworkInterface class. This class allows us to programmatically gather information about our network interfaces, and it is especially useful in cases where we need to do some programming using networks and connections. We will explain some of the most important methods and usage of this class and show the retrieved information.   ...

Read More »

Transient variables in Java

In this post we are going to examine what a transient variable is in Java and learn how to use them in the right context. In order to do that we are going to also take a quick look into the Serializable interface and its usefulness.         1. Object Serialization and “transient” variables Serialization is a process where ...

Read More »

Exceptions Hierarchy and Custom Exceptions in Java

Exceptions are a vital part of every modern programming language, as it is a way to handle error cases and unexpected behavior, without necessarily terminating the whole application. Except for that, by handling the exceptions in the correct way, we can get meaningful feedback regarding what went wrong, why and where. As you can understand, it is very important for every ...

Read More »

Servlet Lifecycle Example

In this example we are going to examine what is the servlet lifecycle and how it all works out in the servlet container. Basically, by “lifecycle”, we actually mean the whole process of creating and initializing the servlet, using it and destroying it when it is no longer needed. In the GenericServlet abstract class (which is extended by all the ...

Read More »

JSP Implicit Objects Example

In this example we are going to explain what are the implicit objects in a jsp page and what is their functionality, as well as show some examples of their usage. 1. Implicit objects in a jsp page When we are creating a Java web application, we are using some Java specific technologies, more specifically servlets and jsp pages. Jsp ...

Read More »