docs: public static void transferStream(InputStream in, OutputStream out)
     {
         try {
      	   byte[] cbuf = new byte[1000];
             int iLen = 0;
             while ((iLen = in.read(cbuf, 0, cbuf.length)) > 0)
             {   // Write the entire file to the output buffer
                 out.write(cbuf, 0, iLen);
             }
             in.close();
         } catch (MalformedURLException ex)  {
             ex.printStackTrace();
         } catch (IOException ex) {
             ex.printStackTrace();
         }
     }