public Injector build() { if (shellBuilder == null) { throw new AssertionError("Already built, builders are not reusable."); } // Synchronize while we're building up the bindings and other injector state. This ensures that // the JIT bindings in the parent injector don't change while we're being built synchronized (shellBuilder.lock()) { shells = shellBuilder.build(initializer, bindingData, stopwatch, errors); stopwatch.resetAndLog("Injector construction"); initializeStatically(); } injectDynamically(); if (shellBuilder.getStage() == Stage.TOOL) { // wrap the primaryInjector in a ToolStageInjector // to prevent non-tool-friendy methods from being called. return new ToolStageInjector(primaryInjector()); } else { return primaryInjector(); } }
public Injector build() { if (shellBuilder == null) { throw new AssertionError("Already built, builders are not reusable."); } // Synchronize while we're building up the bindings and other injector state. This ensures that // the JIT bindings in the parent injector don't change while we're being built synchronized (shellBuilder.lock()) { shells = shellBuilder.build(initializer, bindingData, stopwatch, errors); stopwatch.resetAndLog("Injector construction"); initializeStatically(); } injectDynamically(); if (shellBuilder.getStage() == Stage.TOOL) { // wrap the primaryInjector in a ToolStageInjector // to prevent non-tool-friendy methods from being called. return new ToolStageInjector(primaryInjector()); } else { return primaryInjector(); } }
public Injector build() { if (shellBuilder == null) { throw new AssertionError("Already built, builders are not reusable."); } // Synchronize while we're building up the bindings and other injector state. This ensures that // the JIT bindings in the parent injector don't change while we're being built synchronized (shellBuilder.lock()) { shells = shellBuilder.build(initializer, bindingData, stopwatch, errors); stopwatch.resetAndLog("Injector construction"); initializeStatically(); } injectDynamically(); if (shellBuilder.getStage() == Stage.TOOL) { // wrap the primaryInjector in a ToolStageInjector // to prevent non-tool-friendy methods from being called. return new ToolStageInjector(primaryInjector()); } else { return primaryInjector(); } }
public Injector build() { if (shellBuilder == null) { throw new AssertionError("Already built, builders are not reusable."); } // Synchronize while we're building up the bindings and other injector state. This ensures that // the JIT bindings in the parent injector don't change while we're being built synchronized (shellBuilder.lock()) { shells = shellBuilder.build(initializer, bindingData, stopwatch, errors); stopwatch.resetAndLog("Injector construction"); initializeStatically(); } injectDynamically(); if (shellBuilder.getStage() == Stage.TOOL) { // wrap the primaryInjector in a ToolStageInjector // to prevent non-tool-friendy methods from being called. return new ToolStageInjector(primaryInjector()); } else { return primaryInjector(); } }
public Injector build() { if (shellBuilder == null) { throw new AssertionError("Already built, builders are not reusable."); } // Synchronize while we're building up the bindings and other injector state. This ensures that // the JIT bindings in the parent injector don't change while we're being built synchronized (shellBuilder.lock()) { shells = shellBuilder.build(initializer, bindingData, stopwatch, errors); stopwatch.resetAndLog("Injector construction"); initializeStatically(); } injectDynamically(); if (shellBuilder.getStage() == Stage.TOOL) { // wrap the primaryInjector in a ToolStageInjector // to prevent non-tool-friendy methods from being called. return new ToolStageInjector(primaryInjector()); } else { return primaryInjector(); } }
public Injector build() { if (shellBuilder == null) { throw new AssertionError("Already built, builders are not reusable."); } // Synchronize while we're building up the bindings and other injector state. This ensures that // the JIT bindings in the parent injector don't change while we're being built synchronized (shellBuilder.lock()) { shells = shellBuilder.build(initializer, bindingData, stopwatch, errors); stopwatch.resetAndLog("Injector construction"); initializeStatically(); } injectDynamically(); if (shellBuilder.getStage() == Stage.TOOL) { // wrap the primaryInjector in a ToolStageInjector // to prevent non-tool-friendy methods from being called. return new ToolStageInjector(primaryInjector()); } else { return primaryInjector(); } }
public Injector build() { // Synchronize while we're building up the bindings and other injector state. This ensures that // the JIT bindings in the parent injector don't change while we're being built synchronized (shellBuilder.lock()) { shells = shellBuilder.build(initializer, bindingData, stopwatch, errors); stopwatch.resetAndLog("Injector construction"); initializeStatically(); } injectDynamically(); if (shellBuilder.getStage() == Stage.TOOL) { // wrap the primaryInjector in a ToolStageInjector // to prevent non-tool-friendy methods from being called. return new ToolStageInjector(primaryInjector()); } else { return primaryInjector(); } }