@Override public void addCodeBase(ICodeBaseLocator locator, boolean isApplication) { addToWorkList(projectWorkList, new WorkListItem(locator, isApplication, ICodeBase.Discovered.SPECIFIED)); }
/** * Add worklist items from given system classpath. * * @param workList * the worklist * @param path * a system classpath */ private void addWorkListItemsForClasspath(LinkedList<WorkListItem> workList, String path) { if (path == null) { return; } StringTokenizer st = new StringTokenizer(path, File.pathSeparator); while (st.hasMoreTokens()) { String entry = st.nextToken(); if (DEBUG) { System.out.println("System classpath entry: " + entry); } addToWorkList(workList, new WorkListItem(classFactory.createFilesystemCodeBaseLocator(entry), false, ICodeBase.Discovered.IN_SYSTEM_CLASSPATH)); } }
/** * Add worklist items from given extensions directory. * * @param workList * the worklist * @param extDir * an extensions directory */ private void addWorkListItemsForExtDir(LinkedList<WorkListItem> workList, String extDir) { File dir = new File(extDir); File[] fileList = dir.listFiles((FileFilter) pathname -> { String path = pathname.getPath(); boolean isArchive = Archive.isArchiveFileName(path); return isArchive; }); if (fileList == null) { return; } for (File archive : fileList) { addToWorkList(workList, new WorkListItem(classFactory.createFilesystemCodeBaseLocator(archive.getPath()), false, ICodeBase.Discovered.IN_SYSTEM_CLASSPATH)); } }
addToWorkList(workList, new WorkListItem(relativeCodeBaseLocator, false, ICodeBase.Discovered.IN_JAR_MANIFEST));
addToWorkList(workList, new WorkListItem(nestedArchiveLocator, codeBase.isApplicationCodeBase(), ICodeBase.Discovered.NESTED));
@Override public void addCodeBase(ICodeBaseLocator locator, boolean isApplication) { addToWorkList(projectWorkList, new WorkListItem(locator, isApplication, ICodeBase.Discovered.SPECIFIED)); }
/** * Add worklist items from given system classpath. * * @param workList * the worklist * @param path * a system classpath */ private void addWorkListItemsForClasspath(LinkedList<WorkListItem> workList, String path) { if (path == null) { return; } StringTokenizer st = new StringTokenizer(path, File.pathSeparator); while (st.hasMoreTokens()) { String entry = st.nextToken(); if (DEBUG) { System.out.println("System classpath entry: " + entry); } addToWorkList(workList, new WorkListItem(classFactory.createFilesystemCodeBaseLocator(entry), false, ICodeBase.Discovered.IN_SYSTEM_CLASSPATH)); } }
addToWorkList(workList, new WorkListItem(classFactory.createFilesystemCodeBaseLocator(archive.getPath()), false, ICodeBase.Discovered.IN_SYSTEM_CLASSPATH));
addToWorkList(workList, new WorkListItem(relativeCodeBaseLocator, false, ICodeBase.Discovered.IN_JAR_MANIFEST));
addToWorkList(workList, new WorkListItem(nestedArchiveLocator, codeBase.isApplicationCodeBase(), ICodeBase.Discovered.NESTED));