@Override public CommandResult execute() { furnace.addRepository(AddonRepositoryMode.MUTABLE, new File(directory)); return CommandResult.CONTINUE; }
@Override public CommandResult execute() { furnace.addRepository(AddonRepositoryMode.IMMUTABLE, new File(directory)); return CommandResult.CONTINUE; }
@Override public CommandResult execute() { furnace.addRepository(AddonRepositoryMode.IMMUTABLE, new File(directory)); return CommandResult.CONTINUE; }
@Override public CommandResult execute() { furnace.addRepository(AddonRepositoryMode.MUTABLE, new File(directory)); return CommandResult.CONTINUE; }
@Override public MutableAddonRepository call() throws Exception { return (MutableAddonRepository) runnable.furnace.addRepository(AddonRepositoryMode.MUTABLE, new File(addonDir, OperatingSystemUtils.getSafeFilename(repositoryName))); } });
private void initContainer() { runnable = new ForgeRunnable(ClassLoader.getSystemClassLoader()); furnaceHolder.setFurnace(runnable.furnace); thread = new Thread(runnable, "Arquillian Furnace Runtime"); repository = (MutableAddonRepository) runnable.furnace.addRepository(AddonRepositoryMode.MUTABLE, addonDir); }
public Furnace setup(AddonRepositoryMode mode, File repoDir) { // Initialize Furnace ClassLoader ccl = Thread.currentThread().getContextClassLoader(); furnace = create(ccl, ccl); furnace.setAddonCompatibilityStrategy(AddonCompatibilityStrategies.LENIENT); furnace.addRepository(mode, repoDir); return furnace; }
public void setup(Path repoDir) { LOG.info("Starting with repo: " + repoDir); Furnace furnace; try { furnace = FurnaceFactory.getInstance(Thread.currentThread() .getContextClassLoader(), Thread.currentThread() .getContextClassLoader()); } catch (Exception cnfe) { LOG.info("Furnace not found with TCCL, trying local CL"); furnace = FurnaceFactory.getInstance(this.getClass().getClassLoader(), this.getClass().getClassLoader()); } furnace.addRepository(AddonRepositoryMode.IMMUTABLE, repoDir.toFile()); Future<Furnace> future = furnace.startAsync(); try { future.get(); } catch (InterruptedException | ExecutionException e) { throw new RuntimeException("Furnace failed to start.", e); } this.furnace = furnace; }
public void setup(File repoDir) { furnace = FurnaceFactory.getInstance(Thread.currentThread() .getContextClassLoader(), Thread.currentThread() .getContextClassLoader()); furnace.addRepository(AddonRepositoryMode.IMMUTABLE, repoDir); Future<Furnace> future = furnace.startAsync(); try { future.get(); } catch (InterruptedException | ExecutionException e) { throw new RuntimeException("Furnace failed to start.", e); } AddonRegistry addonRegistry = furnace.getAddonRegistry(); commandFactory = addonRegistry.getServices(CommandFactory.class).get(); controllerFactory = (CommandControllerFactory) addonRegistry .getServices(CommandControllerFactory.class.getName()).get(); }
public void setup(File repoDir) { furnace = FurnaceFactory.getInstance(Thread.currentThread() .getContextClassLoader(), Thread.currentThread() .getContextClassLoader()); furnace.addRepository(AddonRepositoryMode.IMMUTABLE, repoDir); Future<Furnace> future = furnace.startAsync(); try { future.get(); } catch (InterruptedException | ExecutionException e) { throw new RuntimeException("Furnace failed to start.", e); } AddonRegistry addonRegistry = furnace.getAddonRegistry(); commandFactory = addonRegistry.getServices(CommandFactory.class).get(); controllerFactory = (CommandControllerFactory) addonRegistry .getServices(CommandControllerFactory.class.getName()).get(); dependencyResolver = (DependencyResolver) addonRegistry .getServices(DependencyResolver.class.getName()).get(); }
furnace.addRepository(AddonRepositoryMode.MUTABLE, new File(args[++i])); furnace.addRepository(AddonRepositoryMode.IMMUTABLE, new File(args[++i])); furnace.addRepository(AddonRepositoryMode.MUTABLE, new File(OperatingSystemUtils.getUserForgeDir(), "addons"));
furnace.addRepository(AddonRepositoryMode.MUTABLE, new File(args[++i])); furnace.addRepository(AddonRepositoryMode.IMMUTABLE, new File(args[++i])); furnace.addRepository(AddonRepositoryMode.MUTABLE, new File(OperatingSystemUtils.getUserForgeDir(), "addons"));
furnace.addRepository(AddonRepositoryMode.MUTABLE, getUserAddonsDir());
furnace.addRepository(AddonRepositoryMode.MUTABLE, getUserAddonsDir());