private URL[] pathToURLs(String path) {
        Set<URL> urls = new LinkedHashSet<URL>();
        for (String s: path.split(File.pathSeparator)) {
            if (s.isEmpty()) continue;
            try {
                urls.add(new File(s).getAbsoluteFile().toURI().toURL());
            } catch (MalformedURLException e) {
                message.error("doclet.MalformedURL", s);
            }
        }
        return urls.toArray(new URL[urls.size()]);
    }
private URL [ ] pathToURLs ( String path ) { Set < URL > urls = new LinkedHashSet < URL > ( ) ; for ( String s : path . split ( File . pathSeparator ) ) { if ( s . isEmpty ( ) ) continue ; try { urls . add ( new File ( s ) . getAbsoluteFile ( ) . toURI ( ) . toURL ( ) ) ; } catch ( MalformedURLException e ) { message . error ( "doclet.MalformedURL" , s ) ; } } return urls . toArray ( new URL [ urls . size ( ) ] ) ; }
Utility method for converting a search path string to an array
of directory and JAR file URLs.

@param path the search path string
@return the resulting array of directory and JAR file URLs