code: private static URL[] pathToURLs(String path) {
          java.util.List<URL> urls = new ArrayList<>();
          for (String s: path.split(Pattern.quote(File.pathSeparator))) {
              if (!s.isEmpty()) {
                  URL url = fileToURL(Paths.get(s));
                  if (url != null) {
                      urls.add(url);
                  }
              }
          }
          return urls.toArray(new URL[urls.size()]);
      }
docs: Utility method for converting a search path string to an array of directory and JAR file
  URLs.
  
  Note that this method is called by the DocletInvoker.
  
  @param path the search path string
  @return the resulting array of directory and JAR file URLs