T
Tony Johansson
Hello!
I want to be able to use the correct terminology when talking about
generics.
The text says "If generics are used in the program, it helps when generic
types can be distinguished from non-generic types.
Here are naming guidelines for generic types:
* Generic type names should be prefixed with letter T.
*If generic type can be replaced by any class because there's no special
requirement, and only one generic type is used,
the character T is good as a generic type name."¨
My first question is about terminology. If someone say generic type as is
used in this text what is it supposed that it mean ?
I would say that List<T> is a generic type is that correct terminology ?
But why not say generic class insted of generic type ?
My second question the text says that generic type should be prefix with T
then List<T> should be called TList<T> .
My third question the text say the character T is good as a generic type
name is that actually correct used terminology ?
//Tony
I want to be able to use the correct terminology when talking about
generics.
The text says "If generics are used in the program, it helps when generic
types can be distinguished from non-generic types.
Here are naming guidelines for generic types:
* Generic type names should be prefixed with letter T.
*If generic type can be replaced by any class because there's no special
requirement, and only one generic type is used,
the character T is good as a generic type name."¨
My first question is about terminology. If someone say generic type as is
used in this text what is it supposed that it mean ?
I would say that List<T> is a generic type is that correct terminology ?
But why not say generic class insted of generic type ?
My second question the text says that generic type should be prefix with T
then List<T> should be called TList<T> .
My third question the text say the character T is good as a generic type
name is that actually correct used terminology ?
//Tony