包属性 | |
| final Class<?super T > | rawType |
| final Type | type |
| final int | hashCode |
Represents a generic type
. Java doesn't yet provide a way to represent generic types, so this class does. Forces clients to create a subclass of this class which enables retrieval the type information even at runtime.
For example, to create a type literal for
, you can create an empty anonymous inner class:
This syntax cannot be used to create type literals that have wildcard parameters, such as
or
.
|
package |
|
package |
|
package |
1.8.8