The Visitor design pattern is another behavioral pattern that simplifies access to an object’s data collections. Moreover, it is closely related to the Iterator design pattern. Unlike the Iterator pattern, the Visitor pattern makes client codes visit one data item
Maven – Redirect console output to file
Sometimes we need to redirect Maven console output to a file. Your favorite IDEs may not display all the console output. It is normal as some IDEs have a default configuration to show only the last part of the overall
Using @Conditional with @Configuration in Spring
Using @Conditional with @Configuration in Spring allows us to group @Bean objects loaded on a specific condition without resorting to using @Profile and too many @Bean/@Conditional. Requirements We used the following items for this post. Spring Boot 2.0.4.RELEASE JDK 8
The Iterator Design Pattern in Simple Words
The Iterator design pattern is a behavioral design pattern that simplifies access to an object’s data collections. Moreover, it aims to provide a simple mechanism to make the data available. As a result, the client codes do not need to
Eclipse Mars and Project Lombok
For Eclipse Mars.2 Release (4.5.2), Lombok 1.16.16 works in generating those getters and setters. If you are new to using Project Lombok, chances are you’ve tried a wrong version of it for your Eclipse.
JAXB Pre And Post-processing with Unmarshaller Listener
This post shows how to perform JAXB pre and post-processing with Unmarshaller Listener. For instance, you may want to compare the contents of an object before and after you unmarshal an XML. Another use-case is when you may need to
Flyweight Design Pattern in Java
The Flyweight design pattern can be summarized in three (3) words – minimize and share. In fact, I would label it as “minimize-and-share”. It makes it easier to remember and relate to the actual solution.
Chain of Responsibility Pattern Example In Rust
This post shows a simple implementation of the Chain of Responsibility pattern in Rust. For example, we have a set of struct instances that check for a file, read it, and finally, display it. We could imagine these instances as
Chain of Responsibility Design Pattern In Simple Words
The Chain of Responsibility is a behavioral design pattern that processes data using a sequence of loosely-coupled handlers. Each handler receives the data from a handler preceding it. Then, it processes the data. If there are problems with the data,
Installing Java 2 SDK 1.4 in Windows 7
This post shows how to install Java 2 SDK 1.4 in Windows 7. If you’ve worked in IT consulting for some time, you will realize that some clients may still be using older versions of Java. Although this version of