Reflection in java

Good morning,
I would like to explore the package “com.vaadin.ui” to find the classes of each component, which obviously extends CustomComponent. I am currently working on a Maven project and I’m using the ClassLoader class, but it does not works. Do you have any suggestions? Thank you.

I’ve been using
http://code.google.com/p/reflections/
(available in Maven) which really helps when you need to explore the class hierarchy further than just finding a class.

Using Reflections your example would simply be:

Set<Class<? extends CustomComponent>> components = reflections.getSubTypesOf(com.vaadin.ui.CustomComponent.class);

Thank you very much! This helps :wink: