template <class T : public myInterfaceClassName> class ...
Pretty simple uh? But you rarely see people using it, because generic programming and traditional object programming seems to be some sort of competitors.
I couldn't find any reference to this in the draft standard or in Stroustrup and I couldn't get an example like this to compile in g++ 3.4.2 or 3.4.4 (though I know 3.4.2 won't accept some legal stuff like class : public class A { ... } object;)
Puf. Somehow I couldn't make it compile also. I am pretty sure there is some notation like the one above that is valid C++ code (or maybe I just had a dream about it). Well, there are other solutions for this problem. Check out traits: http://www.gotw.ca/gotw/071.htm []s Davi de Castro Reis