Mid From PDF GoF Patterns Gang of Four Patterns

Template Method (Cook):?

  • The Cook method in the Recipe class defines the skeleton of the algorithm.

It calls GatherIngredients, Prepare, CookMethod, and Serve in a fixed

order. The first three steps are abstract and need to be implemented by

subclasses, while the Serve method is concrete and always works the same

way.

More from Design Patterns in C#

All questions for this course
Toolliyo Assistant
Ask about tutorials, ebooks, training, pricing, mentor services, and support. I use public site content only—not admin or internal tools.

care@toolliyo.com

Need callback? Share your details