title: (how) can I download an image using JSoup?
body: <p>I already know where the image is, but for simplicity's sake I wanted to download the image using JSoup itself. (This is to simplify getting cookies, referrer, etc.)</p>
  
  <p>This is what I have so far:</p>
  
  <pre><code>//Open a URL Stream
  Response resultImageResponse = Jsoup.connect(imageLocation).cookies(cookies).ignoreContentType(true).execute();
  
  // output here
  OutputStreamWriter out = new OutputStreamWriter(new FileOutputStream(new java.io.File(outputFolder + name));
  //BufferedWriter out = new BufferedWriter(new FileWriter(outputFolder + name));
  out.write(resultImageResponse.body());          // resultImageResponse.body() is where the image's contents are.
  out.close();
  </code></pre>