I would like to know if there is a possibility to create new classes and make use of them during the runtime of an application. I have heard about Java Reflection API, can it be used to solve my problem ?
Java reflection api is used for creating objects at rumtime , but the classes should be already available.It cannot create classes at runtime.It can load class , instantiate object and other related stuffs.
I've found the Javassist library very useful for this. Since it creates real Java classes, I'd think it would be much faster that anything that involves a scripting language (assuming that those are essentially interpreted, not compiled to bytecode).