A template class is a class that takes a template parameter. Or: a template class defines how a group of classes should be generated, as opposed to a class in C++ as being how the group of objects should be generated:
Many STL classes are template classes.
There is no semantic difference between class and typename in a template-parameter [1].
- Example 1: class holding a templated member variable
- Example 2: class that has a class template type
- Example 3: class that has an integer template type
- Example 4: class that has an enum class template type
- Example 5: copy policy of integer class
- Example 6: copy policy of template class type, two specialized classes
- Example 7: copy policy of template class type, two partially specialized classes
- C++. International Standard. ISO/IEC 14882. Second edition. Paragraph 14.1.2.