@Test public void shouldLoadClassLoaderCorrectlyOnlyOnce() throws Exception { final Class exportedClass = TestJarExporter.class; final File jarFile = jarCreator.create(exportedClass); final ExporterJarClassLoader classLoader = jarRepository.load(jarFile.toPath()); assertThat(classLoader.loadClass(exportedClass.getCanonicalName())).isNotEqualTo(exportedClass); assertThat(jarRepository.load(jarFile.toPath())).isEqualTo(classLoader); }
public ExporterJarClassLoader load(final String jarPath) throws ExporterJarLoadException { return load(Paths.get(jarPath)); }
ExporterJarRepository { public ExporterJarClassLoader load(final String jarPath) throws ExporterJarLoadException { return load(Paths.get(jarPath)); } }
ExporterJarRepository { public ExporterJarClassLoader load(final String jarPath) throws ExporterJarLoadException { return load(Paths.get(jarPath)); } ExporterJarRepository();  ExporterJarRepository(final Map<Path, ExporterJarClassLoader> loadedJars); }
ExporterJarRepository { public ExporterJarClassLoader load(final String jarPath) throws ExporterJarLoadException { return load(Paths.get(jarPath)); } ExporterJarRepository();  ExporterJarRepository(final Map<Path, ExporterJarClassLoader> loadedJars); Map<Path, ExporterJarClassLoader> getJars(); ExporterJarClassLoader remove(final String jarPath); ExporterJarClassLoader remove(final Path jarPath); ExporterJarClassLoader load(final String jarPath); ExporterJarClassLoader load(final Path jarPath); }
ExporterJarRepository { public ExporterJarClassLoader load(final String jarPath) throws ExporterJarLoadException { return load(Paths.get(jarPath)); } ExporterJarRepository();  ExporterJarRepository(final Map<Path, ExporterJarClassLoader> loadedJars); Map<Path, ExporterJarClassLoader> getJars(); ExporterJarClassLoader remove(final String jarPath); ExporterJarClassLoader remove(final Path jarPath); ExporterJarClassLoader load(final String jarPath); ExporterJarClassLoader load(final Path jarPath); static final String JAR_EXTENSION; }