Source:
<code>public void constructMod(FMLConstructionEvent event) { try { if (this.invalid) { throw new InvalidPluginException(); } final ModClassLoader modClassLoader = event.getModClassLoader(); modClassLoader.addFile(getSource()); modClassLoader.clearNegativeCacheFor(this.candidate.getClassList()); final Class<?> pluginClass = Class.forName(this.className, true, modClassLoader); final Type adapterType = (org.objectweb.asm.Type) this.descriptor.get("adapter"); final Class<?> adapterClass; if (adapterType != null) { adapterClass = Class.forName(adapterType.getClassName(), true, modClassLoader); } else { adapterClass = PluginAdapter.Default.class; } Injector injector = spongeInjector.getParent().createChildInjector(new PluginModule((PluginContainer) this)); final ImmutableList.Builder<Module> modules = ImmutableList.builder(); final List<Type> injectionModuleTypes = (List<Type>) this.descriptor.get("injectionModules"); if (injectionModuleTypes != null && injectionModuleTypes.size() > 0) { for (Type injectionModuleType : injectionModuleTypes) { final Class<?> moduleClass = Class.forName(injectionModuleType.getClassName(), true, modClassLoader); <START> modules.add((Module) moduleClass.newInstance()); <END> } } final PluginAdapter adapter = adapterClass == PluginAdapter.Default.class ? DefaultPluginAdapter.INSTANCE : (PluginAdapter) adapterClass.newInstance(); injector = checkNotNull(adapter.createInjector(this.pluginContainer, pluginClass, injector, modules.build()), "The injector cannot be null"); final Binding<?> binding = injector.getBinding(pluginClass); if (!Scopes.isSingleton(binding)) { throw new IllegalStateException("The plugin instance (" + pluginClass.getName() + ") must be bound in the singleton scope."); } this.injector = injector; this.instance = injector.getInstance(pluginClass); ProxyInjector.inject(this, event.getASMHarvestedData(), FMLCommonHandler.instance().getSide(), new ILanguageAdapter.JavaAdapter()); Sponge.getEventManager().registerListeners(this, this.instance); } catch (Throwable t) { this.controller.errorOccurred(this, t); } }</code><technical_language>Create injector, modules depend sponge injectable</technical_language>

Target:
public void constructMod(FMLConstructionEvent event) { try { if (this.invalid) { throw new InvalidPluginException(); } final ModClassLoader modClassLoader = event.getModClassLoader(); modClassLoader.addFile(getSource()); modClassLoader.clearNegativeCacheFor(this.candidate.getClassList()); final Class pluginClass = Class.forName(this.className, true, modClassLoader); final Type adapterType = (org.objectweb.asm.Type) this.descriptor.get("adapter"); final Class<? extends PluginAdapter> adapterClass; if (adapterType != null) { adapterClass = (Class<? extends PluginAdapter>) Class.forName(adapterType.getClassName(), true, modClassLoader); } else { adapterClass = PluginAdapter.Default.class; } final List<Class<? extends Module>> moduleClasses = new ArrayList<>(); final List<Type> injectionModuleTypes = (List<Type>) this.descriptor.get("injectionModules"); if (injectionModuleTypes != null) { for (Type injectionModuleType : injectionModuleTypes) { moduleClasses.add((Class<? extends Module>) Class.forName(injectionModuleType.getClassName(), true, modClassLoader)); } } final Tuple<Object, Injector> tuple = PluginConstructor.constructPlugin(spongeInjector.getParent(), this.pluginContainer, pluginClass, adapterClass, moduleClasses); this.injector = tuple.getSecond(); this.instance = tuple.getFirst(); ProxyInjector.inject(this, event.getASMHarvestedData(), FMLCommonHandler.instance().getSide(), new ILanguageAdapter.JavaAdapter()); Sponge.getEventManager().registerListeners(this, this.instance); } catch (Throwable t) { this.controller.errorOccurred(this, t); } }