try {
Constructor<? extends GinModule> constructor = moduleClass.getDeclaredConstructor();
try {
constructor.setAccessible(true);
if (PrivateGinModule.class.isAssignableFrom(moduleClass)) {
return new PrivateGinModuleAdapter((PrivateGinModule) constructor.newInstance(),
rootGinjectorBindings);
} else {
return new GinModuleAdapter(constructor.newInstance(), rootGinjectorBindings);
}
} finally {