/** * Creates a stream of classes representing the supertypes (excluding Object.class) of the specified type. * * @param type * the type whose supertypes should be returned as a stream * * @return stream of the supertypes of the specified class */ public static Stream<Class> supertypes(final Class type) { return selfAndSupertypes(type.getSuperclass()); }