@Override public Iterable<? extends File> getLocation(Location location) { if (location instanceof LocationWrapper) { return getFiles(((LocationWrapper) location).paths); } LocationWrapper loc = this.locationHandler.getLocation(location, ""); //$NON-NLS-1$ if (loc == null) { return null; } return getFiles(loc.getPaths()); }
@Override public Iterable<Set<Location>> listLocationsForModules(Location location) { validateModuleLocation(location, ""); //$NON-NLS-1$ return this.locationHandler.listLocationsForModules(location); }
protected void initialize(File javahome) throws IOException { if (this.isOnJvm9) { this.jrtSystem = new JrtFileSystem(javahome); this.archivesCache.put(javahome, this.jrtSystem); this.jrtHome = javahome; this.locationHandler.newSystemLocation(StandardLocation.SYSTEM_MODULES, this.jrtSystem); } else { this.setLocation(StandardLocation.PLATFORM_CLASS_PATH, getDefaultBootclasspath()); } Iterable<? extends File> defaultClasspath = getDefaultClasspath(); this.setLocation(StandardLocation.CLASS_PATH, defaultClasspath); // No annotation module path by default this.setLocation(StandardLocation.ANNOTATION_PROCESSOR_PATH, defaultClasspath); }
@Override public int isSupportedOption(String option) { return Options.processOptionsFileManager(option); }
private static void reportEncodingError(EncodingErrorCollector collector, int position, int length) { collector.collect(position, -length); } }
public ArchiveFileObject getArchiveFileObject(String entryName, Charset charset) { return new ArchiveFileObject(this.file, entryName, charset); }
@Override public Location getLocationForModule(Location location, String moduleName) throws IOException { validateModuleLocation(location, moduleName); Location result = this.locationHandler.getLocation(location, moduleName); if (result == null && location == StandardLocation.CLASS_OUTPUT) { LocationWrapper wrapper = this.locationHandler.getLocation(StandardLocation.MODULE_SOURCE_PATH, moduleName); deriveOutputLocationForModules(moduleName, wrapper.paths); result = getLocationForModule(location, moduleName); } else if (result == null && location == StandardLocation.SOURCE_OUTPUT) { LocationWrapper wrapper = this.locationHandler.getLocation(StandardLocation.MODULE_SOURCE_PATH, moduleName); deriveSourceOutputLocationForModules(moduleName, wrapper.paths); result = getLocationForModule(location, moduleName); } return result; }
@Override public Iterable<? extends Path> getLocationAsPaths(Location location) { if (location instanceof LocationWrapper) { return ((LocationWrapper) location).paths; } LocationWrapper loc = this.locationHandler.getLocation(location); if (loc == null) { return null; } return loc.getPaths(); }
@Override public boolean hasLocation(Location location) { try { return getLocationForModule(location, "") != null; //$NON-NLS-1$ } catch (IOException e) { // nothing to do } return false; }
public SystemLocationContainer(Location loc, ClasspathJrt cp) throws IOException { this(loc, new JrtFileSystem(cp.file)); } }
public LocationWrapper(Location loc, boolean output, Iterable<? extends Path> paths) { this.loc = loc; this.output = output; setPaths(paths); }
public JrtFileSystem(File file) throws ZipException, IOException { this.file = file; initialize(); }
@Override public int isSupportedOption(String option) { return Options.processOptionsFileManager(option); }
private static void reportEncodingError(EncodingErrorCollector collector, int position, int length) { collector.collect(position, -length); } }
public int isSupportedOption(String option) { return Options.processOptionsFileManager(option); }
private static void reportEncodingError(EncodingErrorCollector collector, int position, int length) { collector.collect(position, -length); } }
@Override public int isSupportedOption(String option) { return Options.processOptionsFileManager(option); }
private static void reportEncodingError(EncodingErrorCollector collector, int position, int length) { collector.collect(position, -length); } }
public int isSupportedOption(String option) { return Options.processOptionsFileManager(option); }