@Inject public FurnaceServiceProducer(Furnace furnace) { this.addonRegistry = furnace.getAddonRegistry(); }
private AddonRegistry getAddonRegistry() { if (addonRegistry == null) { addonRegistry = SimpleContainer.getFurnace(getClass().getClassLoader()).getAddonRegistry(); } return addonRegistry; }
private AddonRegistry getAddonRegistry() { if (registry == null) { Furnace furnace = SimpleContainer.getFurnace(this.getClass().getClassLoader()); this.registry = furnace.getAddonRegistry(); } return registry; }
private GitIgnoreConfig getGitIgnoreConfig() { if (gitIgnoreConfig == null) { AddonRegistry addonRegistry = SimpleContainer.getFurnace(getClass().getClassLoader()).getAddonRegistry(); gitIgnoreConfig = addonRegistry.getServices(GitIgnoreConfig.class).get(); } return gitIgnoreConfig; }
private ResourceFactory getResourceFactory() { if (factory == null) { AddonRegistry addonRegistry = SimpleContainer.getFurnace(getClass().getClassLoader()).getAddonRegistry(); factory = addonRegistry.getServices(ResourceFactory.class).get(); } return factory; }
private ForgeScriptEngineFactory getEngineFactory() { if (engineFactory == null) { AddonRegistry addonRegistry = Furnace.instance(getClass().getClassLoader()).getAddonRegistry(); this.engineFactory = addonRegistry.getServices(ForgeScriptEngineFactory.class).get(); } return engineFactory; }
private ResourceFactory getResourceFactory() { if (resourceFactory == null) { AddonRegistry addonRegistry = SimpleContainer.getFurnace(getClass().getClassLoader()).getAddonRegistry(); resourceFactory = addonRegistry.getServices(ResourceFactory.class).get(); } return resourceFactory; }
private ConfigurationFactory getConfigFactory() { if (configFactory == null) { AddonRegistry addonRegistry = SimpleContainer.getFurnace(getClass().getClassLoader()).getAddonRegistry(); configFactory = addonRegistry.getServices(ConfigurationFactory.class).get(); } return configFactory; }
private GitUtils getGitUtils() { if (gitUtils == null) { AddonRegistry addonRegistry = SimpleContainer.getFurnace(getClass().getClassLoader()).getAddonRegistry(); gitUtils = addonRegistry.getServices(GitUtils.class).get(); } return gitUtils; }
@Override protected ProjectFactory getProjectFactory() { Furnace furnace = Furnace.instance(getClass().getClassLoader()); AddonRegistry addonRegistry = furnace.getAddonRegistry(); return addonRegistry.getServices(ProjectFactory.class).get(); }
public GraphApiCompositeClassLoaderProvider() { this.furnace = SimpleContainer.getFurnace(GraphApiCompositeClassLoaderProvider.class.getClassLoader()); for (Addon addon : this.furnace.getAddonRegistry().getAddons()) { if (addon.getClassLoader() != null && addon.getClassLoader().equals(GraphApiCompositeClassLoaderProvider.class.getClassLoader())) { this.addon = addon; break; } } }
@Override public T produce(CreationalContext<T> ctx) { return furnaceProducer.getFurnace().getAddonRegistry().getServices(type).iterator().next(); }
/** * @return the possible value choices for the extends input */ protected Collection<JavaResource> getExtendsValueChoices(Project project) { AddonRegistry addonRegistry = Furnace.instance(getClass().getClassLoader()).getAddonRegistry(); ProjectOperations projectOperations = addonRegistry.getServices(ProjectOperations.class).get(); return projectOperations.getProjectClasses(project); }
/** * @return the possible value choices for the implements input */ protected Collection<JavaResource> getImplementsValueChoices(Project project) { AddonRegistry addonRegistry = Furnace.instance(getClass().getClassLoader()).getAddonRegistry(); ProjectOperations projectOperations = addonRegistry.getServices(ProjectOperations.class).get(); return projectOperations.getProjectInterfaces(project); }
private void startServer() { System.out.println("Calling ToolingRMIServer start..."); furnace.getAddonRegistry().getServices(ToolingRMIServer.class).get().startServer(port, Bootstrap.getVersion()); }
private void initRegistry() { FurnaceClasspathScanner furnaceClasspathScanner = getFurnace().getAddonRegistry().getServices(FurnaceClasspathScanner.class).get(); this.registeredTypes = new HashMap<>(); this.typeRegistry = new TypeRegistry(); GraphModelScanner.loadFrames(furnaceClasspathScanner).forEach(this::addTypeToRegistry); }
ForgeScriptEngine(ForgeScriptEngineFactory factory) { this.factory = factory; AddonRegistry addonRegistry = Furnace.instance(getClass().getClassLoader()).getAddonRegistry(); this.shellFactory = addonRegistry.getServices(ShellFactory.class).get(); this.resourceFactory = addonRegistry.getServices(ResourceFactory.class).get(); }
private GraphTypeManager getGraphTypeManager() { if (this.graphTypeManager == null) this.graphTypeManager = getFurnace().getAddonRegistry().getServices(GraphTypeManager.class).get(); return this.graphTypeManager; }
private GraphApiCompositeClassLoaderProvider getGraphApiCompositeClassLoaderProvider() { if (this.graphApiCompositeClassLoaderProvider == null) this.graphApiCompositeClassLoaderProvider = getFurnace().getAddonRegistry().getServices(GraphApiCompositeClassLoaderProvider.class) .get(); return this.graphApiCompositeClassLoaderProvider; }
private GraphApiCompositeClassLoaderProvider getGraphApiCompositeClassLoaderProvider() { if (this.graphApiCompositeClassLoaderProvider == null) this.graphApiCompositeClassLoaderProvider = getFurnace().getAddonRegistry().getServices(GraphApiCompositeClassLoaderProvider.class) .get(); return this.graphApiCompositeClassLoaderProvider; }