code: public static void copy(InputStream source, File destination) throws IOException {
          OutputStream output = null;
  
          try {
              output = new FileOutputStream(destination);
              copy(source, output);
          } finally {
              closeQuietly(output);
          }
      }
docs: Copies the content of an InputStream into a destination File.
  
  @param source the InputStream to copy
  @param destination the target File
  @throws IOException if an error occurs