### Question:
TypeUtils { public static Type getCollectionGeneric(Type type) { return getTypeArguments(type, Collection.class).get(Collection.class.getTypeParameters()[0]); } private  TypeUtils(); static boolean isCollection(Type type); static boolean isMap(Type type); static Type getCollectionGeneric(Type type); static Type getMapValueGeneric(Type type); static Class<?> getRawType(Type type);  }### Answer:
@Test void shouldReturnCollectionGeneric() { Type type = org.apache.commons.lang3.reflect.TypeUtils.parameterize(List.class, String.class); Type collectionGeneric = TypeUtils.getCollectionGeneric(type); assertThat(collectionGeneric).isEqualTo(String.class); }