TType
- The specific type.public interface EquivalentConverter<TType>
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
getGeneric(java.lang.Class<?> genericType,
TType specific)
Retrieve a copy of the generic type from a specific type.
|
TType |
getSpecific(java.lang.Object generic)
Retrieve a copy of the specific type using an instance of the generic type.
|
java.lang.Class<TType> |
getSpecificType()
Due to type erasion, we need to explicitly keep a reference to the specific type.
|
TType getSpecific(java.lang.Object generic)
generic
- - the generic type.java.lang.Object getGeneric(java.lang.Class<?> genericType, TType specific)
genericType
- - class or super class of the generic type.specific
- - the specific type we need to copy.java.lang.Class<TType> getSpecificType()