Skip to content

Commit

Permalink
update visitor pattern code
Browse files Browse the repository at this point in the history
  • Loading branch information
saltukalakus committed Dec 13, 2024
1 parent 07aa718 commit ec8ea4d
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions src/patterns/behavioral/command.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,6 @@

The Command Design Pattern is a behavioral design pattern that turns a request into a stand-alone object that contains all information about the request. This transformation allows for parameterization of methods with different requests, queuing of requests, and logging of the requests. It also provides support for undoable operations. <br/>

### Components of Command Pattern

1. **Command**: Declares an interface for executing an operation.
2. **ConcreteCommand**: Implements the Command interface and defines a binding between a Receiver object and an action.
3. **Client**: Creates a ConcreteCommand object and sets its receiver.
4. **Invoker**: Asks the command to carry out the request.
5. **Receiver**: Knows how to perform the operations associated with carrying out a request.

Here is an example of the Command Design Pattern:

```rust
Expand Down

0 comments on commit ec8ea4d

Please sign in to comment.