/** Augment the class names associated with a UCL. * @param cl the UCL that loads from url * @param classNamesMap the Map<cl, String[]> to update * @param url the URL to parse for class names * @param prevClassNames the set of pckage names already associated with cl * @return the updated list of class names * @throws Exception */ public static String[] updateClassNamesMap(Object cl, Map classNamesMap, URL url, String[] prevClassNames) throws Exception { ClassPathIterator cpi = new ClassPathIterator(url); HashSet classNameSet = null; if (prevClassNames == null) classNameSet = new HashSet(); else classNameSet = new HashSet(Arrays.asList(prevClassNames)); return updateClassNamesMap(cl, classNamesMap, cpi, classNameSet); }
/** Augment the class names associated with a UCL. * @param cl the UCL that loads from url * @param classNamesMap the Map<cl, String[]> to update * @param url the URL to parse for class names * @param prevClassNames the set of pckage names already associated with cl * @return the updated list of class names * @throws Exception */ public static String[] updateClassNamesMap(Object cl, Map classNamesMap, URL url, String[] prevClassNames) throws Exception { ClassPathIterator cpi = new ClassPathIterator(url); HashSet classNameSet = null; if (prevClassNames == null) classNameSet = new HashSet(); else classNameSet = new HashSet(Arrays.asList(prevClassNames)); return updateClassNamesMap(cl, classNamesMap, cpi, classNameSet); }