title: Difference between Byte[] and InputStream in FileTranfer (DWR)
body: <p>I wanted to know about the difference between these two block of lines of codes.</p>
  
  <pre><code> byte[] fileBytes = FileUtils.readFileToByteArray(new File(completeFilePath.toString()));
    ..
   return new FileTransfer(errorFileName, "application/vnd.ms-excel", is);
  </code></pre>
  
  <p>and</p>
  
  <pre><code> File csvFile = new File(completeFilePath.toString());
   InputStream is = new BufferedInputStream(new FileInputStream(csvFile));
   return new FileTransfer(errorFileName, "application/vnd.ms-excel", is);
  </code></pre>
  
  <p>any advantage and disadvantage for either of them is welcome to clear out detail.
  Thanks in Advance.</p>