The Visitor pattern is a behavioral design pattern that aims to separate algorithms from object structures, making it possible to define new operations without modifying the element class. The core idea of this pattern is to add a method that accepts a visitor to the element class, thereby enabling the ability to perform different operations on different elements.
The Template Method pattern is a behavioral design pattern that defines the skeleton of an algorithm in a superclass, allowing subclasses to rewrite specific steps of the algorithm without modifying the structure.
Strategy is a behavioral design pattern that defines a series of algorithms, encapsulates each algorithm, and makes them interchangeable. Strategy pattern allows algorithms to change independently of the client.
The State pattern is a behavioral design pattern that allows an object to change its behavior when its internal state changes. The key idea of the State pattern is to encapsulate the state of an object into an independent class and delegate the behavior of the object to the object of the current state. In this way, when the state of the object changes, its behavior will also change accordingly.
The Observer pattern is a behavioral design pattern that allows you to define a subscription mechanism that notifies multiple other objects that 'observe' an object when an event occurs on that object.
The Mediator pattern is a behavioral design pattern that reduces the coupling between objects by transferring direct communication between objects to a mediator object. This pattern is used to handle the interaction between an object and other objects so that the objects do not need to know each other directly.