dimanche 29 décembre 2019

What is the difference between a template class design pattern and generic template class in a programming language like Java?

I am taking this basic course in design patterns that explains "Template-And-Hook Patterns" as an introduction by starting with the "Template Method Pattern" then goes a little bit complex into "Template Class Patterns" and finally the "Generic Template Class Patterns".

What still unclear to me is what the "Generic Template Class" really adds to this ?

Here is how it was explained:

enter image description here

Where do we exactly see the static generic expansion here ?

Aucun commentaire:

Enregistrer un commentaire