Design Pattern: Visitor Pattern in Java
Visitor pattern is used to move the operation/calculation part from a group of classes to a completely separate(Visitor) class. This article demonstrates Visitor pattern implementations in Java.
Visitor pattern is used to move the operation/calculation part from a group of classes to a completely separate(Visitor) class. This article demonstrates Visitor pattern implementations in Java.
Template Method pattern is used to implement a process where subclasses can change some steps of the parent. This article demonstrates Template Method pattern implementations in Java.
State pattern is used to change the behavior of an object when the state is changed. With the change in state, the behavior of that object is completely changed. This article demonstrates State pattern implementations in Java.
Observer pattern is used to automatically notify state change in object to all its dependent objects. It works as a pub/sub for state change between objects. This article demonstrates Observer pattern implementations in Java.
Memento pattern is used to store the history of state changes of an object so that that history can be used to track back the change or be used for some other purpose. This article demonstrates Memento pattern implementations in Java.
Mediator pattern is used to restrict direct interaction between objects. A mediator class works as the middleman/communicator when one object wants to connect/use another object. This article demonstrates Mediator pattern implementations in Java. Check the following examples.
Iterator pattern is used to traverse and iterate through a list of items. This article demonstrates Iterator pattern implementations in Java.
Interpreter pattern is used to represent any language operation in Object Oriented Programming context. This article demonstrates Interpreter pattern implementations in Java.
Command pattern is used to encapsulate/wrap a command in an object so that the object can be sent as a parameter and can be used in other places. This article demonstrates Command pattern implementations in Java. Check the following examples.
Chain of Responsibility pattern is used to decouple the request and response handling. Multiple objects create a chain that is used to handle a request. This article demonstrates Chain of Responsibility pattern implementations in Java. Check the following examples.