code: public boolean link(String url, String pkglisturl,
                                DocErrorReporter reporter, boolean linkoffline) {
          this.linkoffline = linkoffline;
          try {
              url = adjustEndFileSeparator(url);
              if (isUrl(pkglisturl)) {
                  readPackageListFromURL(url, toURL(adjustEndFileSeparator(pkglisturl)));
              } else {
                  readPackageListFromFile(url, DocFile.createFileForInput(configuration, pkglisturl));
              }
              return true;
          } catch (Fault f) {
              reporter.printWarning(f.getMessage());
              return false;
          }
      }
docs: Build the extern package list from given URL or the directory path.
  Flag error if the "-link" or "-linkoffline" option is already used.
  
  @param url        URL or Directory path.
  @param pkglisturl This can be another URL for "package-list" or ordinary
  file.
  @param reporter   The <code>DocErrorReporter</code> used to report errors.
  @param linkoffline True if -linkoffline is used and false if -link is used.