@@ -0,0 +1,648 @@
+package de.sambalmueslie.herold.util;%0A%0Aimport java.lang.reflect.Field;%0Aimport java.util.Arrays;%0Aimport java.util.HashSet;%0Aimport java.util.Set;%0Aimport java.util.stream.Stream;%0A%0Apublic class ReflectionUtils %7B%0A%09public static Stream%3CField%3E getAllFields(Class%3C?%3E type) %7B%0A%09%09final Set%3CField%3E fields = getFields(type);%0A%09%09return fields.stream();%0A%09%7D%0A%0A%09public static Set%3CField%3E getFields(Class%3C?%3E type) %7B%0A%09%09final Set%3CField%3E fields = new HashSet%3C%3E();%0A%09%09fields.addAll(Arrays.asList(type.getDeclaredFields()));%0A%0A%09%09final Class%3C?%3E superclass = type.getSuperclass();%0A%09%09if (superclass != null) %7B%0A%09%09%09fields.addAll(getFields(superclass));%0A%09%09%7D%0A%0A%09%09return fields;%0A%0A%09%7D%0A%7D%0A

make tests running