Skip to content

Latest commit

 

History

History

template-method

Template Method Design Pattern

Video Lecture

Section Video Links
Template Method Pattern Template Method Template Method Pattern
Template Method Use Case Template Method Use Case Template Method Use Case

Book

Cover Links
Design Patterns In TypeScript (ASIN : B0948BCH24)    https://www.amazon.com/dp/B0948BCH24
   https://www.amazon.co.uk/dp/B0948BCH24
   https://www.amazon.in/dp/B094716FD6
   https://www.amazon.de/dp/B0948BCH24
   https://www.amazon.fr/dp/B0948BCH24
   https://www.amazon.es/dp/B0948BCH24
   https://www.amazon.it/dp/B0948BCH24
   https://www.amazon.co.jp/dp/B0948BCH24
   https://www.amazon.ca/dp/B0948BCH24
   https://www.amazon.com.au/dp/B0948BCH24

Overview

... Refer to Book or Design Patterns in TypeScript website to read textual content.

Terminology

... Refer to Book or Design Patterns in TypeScript website to read textual content.

Template Method UML Diagram

Template Method UML Diagram

Output

node ./dist/template-method/template-method-concept.js
Class_A : Step Two (overridden)
Step Three is a hook that prints this line by default.
Class_B : Step One (overridden)
Class_B : Step Two. (overridden)
Class_B : Step Three. (overridden)

Template Method Use Case

... Refer to Book or Design Patterns in TypeScript website to read textual content.

Template Method Use Case UML Diagram

Template Method Use Case UML Diagram

Output

node ./dist/template-method/client.js
----------------------
title   : New Text Document
bg-col  : white
text    : Some Text
footer  : -- Page 1 --

<html>
  <head>
    <title>New HTML Document</title>
    <style>
      body {
        background-color: white;
      }
    </style>
  </head>
  <body>
    <p>Line 1</p>
    <p>Line 2</p>
  </body>
</html>

Summary

... Refer to Book or Design Patterns in TypeScript website to read textual content.