Package com.google.common.reflect
Class TypeToken.TypeCollector<K>
java.lang.Object
com.google.common.reflect.TypeToken.TypeCollector<K>
- Type Parameters:
K- The type "kind". Either a TypeToken, or Class.
- Direct Known Subclasses:
TypeToken.TypeCollector.ForwardingTypeCollector
Collects parent types from a sub type.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static class -
Field Summary
FieldsModifier and TypeFieldDescription(package private) static final TypeToken.TypeCollector<TypeToken<?>>(package private) static final TypeToken.TypeCollector<Class<?>> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) final TypeToken.TypeCollector<K>For just classes, we don't have to traverse interfaces.(package private) ImmutableList<K>collectTypes(Iterable<? extends K> types) (package private) final ImmutableList<K>collectTypes(K type) private intcollectTypes(K type, Map<? super K, Integer> map) Collects all types to map, and returns the total depth from T up to Object.getInterfaces(K type) (package private) abstract Class<?>getRawType(K type) (package private) abstract KgetSuperclass(K type) private static <K,V> ImmutableList<K> sortKeysByValue(Map<K, V> map, Comparator<? super V> valueComparator)
-
Field Details
-
FOR_GENERIC_TYPE
-
FOR_RAW_TYPE
-
-
Constructor Details
-
TypeCollector
private TypeCollector()
-
-
Method Details
-
classesOnly
For just classes, we don't have to traverse interfaces. -
collectTypes
-
collectTypes
-
collectTypes
Collects all types to map, and returns the total depth from T up to Object. -
sortKeysByValue
private static <K,V> ImmutableList<K> sortKeysByValue(Map<K, V> map, Comparator<? super V> valueComparator) -
getRawType
-
getInterfaces
-
getSuperclass
-