diff --git a/table-module/README.md b/table-module/README.md index e69892bb7..a613d6879 100644 --- a/table-module/README.md +++ b/table-module/README.md @@ -28,6 +28,10 @@ In plain words > The Table Module pattern centralizes and encapsulates database access logic for a specific table, simplifying data retrieval and manipulation while hiding database complexities. +Flowchart + +![Table Module flowchart](./etc/table-module-flowchart.png) + ## Programmatic Example of Table Module Pattern in Java In the user system example, the domain logic for user login and registration needs to be managed. By using the Table Module pattern, we can create an instance of the `UserTableModule` class to encapsulate and handle all business logic associated with the rows in the user table. diff --git a/table-module/etc/table-module-flowchart.png b/table-module/etc/table-module-flowchart.png new file mode 100644 index 000000000..489d4c8be Binary files /dev/null and b/table-module/etc/table-module-flowchart.png differ diff --git a/template-method/README.md b/template-method/README.md index a05d77ff0..187b5cd6d 100644 --- a/template-method/README.md +++ b/template-method/README.md @@ -34,6 +34,10 @@ Wikipedia says > In object-oriented programming, the template method is one of the behavioral design patterns identified by Gamma et al. in the book Design Patterns. The template method is a method in a superclass, usually an abstract superclass, and defines the skeleton of an operation in terms of a number of high-level steps. These steps are themselves implemented by additional helper methods in the same class as the template method. +Sequence diagram + +![Template Method Pattern Sequence Diagram](./etc/template-method-sequence-diagram.png) + ## Programmatic Example of Template Method Pattern in Java Our programmatic example is about thieves and stealing. The general steps in stealing an item are the same. First, you pick the target, next you confuse him somehow and finally, you steal the item. However, there are many ways to implement these steps. diff --git a/template-method/etc/template-method-sequence-diagram.png b/template-method/etc/template-method-sequence-diagram.png new file mode 100644 index 000000000..57cd0809f Binary files /dev/null and b/template-method/etc/template-method-sequence-diagram.png differ