Exemple #1
0
  public static List<String> multiFetch() throws IOException {
    List<String> outputFiles = new ArrayList<String>();
    for (String sourceUrlPath : fetcherOptions.getSources()) {
      outputFiles.add(fetch(sourceUrlPath));
    }

    return outputFiles;
  }
Exemple #2
0
  private static String fetch(String sourceUrlPath) throws IOException {
    String destinationDirectory = fetcherOptions.getDumpDir();
    String downloadedFilePath = download(sourceUrlPath, destinationDirectory);

    if (geogaddiOptions.isUncompress()) {
      return destinationDirectory + Utils.uncompress(downloadedFilePath, destinationDirectory);
    } else {
      return destinationDirectory + downloadedFilePath;
    }
  }