@Test public void testGetMapKeyType() throws Exception { GenericType type = new GenericType(Sub.class, Super.class.getField("map").getGenericType()); assertEquals(String.class, type.getMapKeyType().getRawType()); }
public GenericType getMapKeyType() { return getTypeArgument(MAP_KEY_TYPE_VAR, Map.class); }
GenericType { public GenericType getMapKeyType() { return getTypeArgument(MAP_KEY_TYPE_VAR, Map.class); } }
GenericType { public GenericType getMapKeyType() { return getTypeArgument(MAP_KEY_TYPE_VAR, Map.class); } GenericType(Class<?> declaringClass, Type type); }
GenericType { public GenericType getMapKeyType() { return getTypeArgument(MAP_KEY_TYPE_VAR, Map.class); } GenericType(Class<?> declaringClass, Type type); Class<?> getRawType(); String toString(); GenericType getArrayElementType(); GenericType getElementType(); GenericType getListElementType(); GenericType getMapKeyType(); GenericType getMapValueType(); GenericType getSetElementType(); boolean isArray(); boolean isList(); boolean isMap(); boolean isSet(); }
GenericType { public GenericType getMapKeyType() { return getTypeArgument(MAP_KEY_TYPE_VAR, Map.class); } GenericType(Class<?> declaringClass, Type type); Class<?> getRawType(); String toString(); GenericType getArrayElementType(); GenericType getElementType(); GenericType getListElementType(); GenericType getMapKeyType(); GenericType getMapValueType(); GenericType getSetElementType(); boolean isArray(); boolean isList(); boolean isMap(); boolean isSet();  }