Adding java code for post "Java - Reflection tutorial"