2

Can an abstract class in an implementation of the Template Method pattern have more than one template method?

Dave Schweisguth
  • 36,475
  • 10
  • 98
  • 121
JUM
  • 25
  • 3

1 Answers1

2

Yes. The Template Method design pattern is about allowing derived classes to implement parts of an algorithm for which the base class provides the basic structure.

The base class defines a template method for each portion of the algorithm that the derived classes would have to implement.

Enrico Campidoglio
  • 56,676
  • 12
  • 126
  • 154