Java - Create new Instance using Reflection without knowing constructor params
问题 I need to create new instances of many classes. I'm using reflection but when I make c.newInstance(), the classes without 'empty parameter constructor' throws an java.lang.InstantiationException. Now, how can i do to create instances of every classes ? I know that i can use c.getConstructor(Class).newinstance(params) to create instances of classes that doesn't have 'empty parameter constructor', but i do not know the params of each classes. One more thing, all those classes extend from