title: Generate file of given size
body: <p>For test purposes I'd like to get file of given size filled with random data.</p>
  
  <p>So I have two questions:</p>
  
  <ul>
  <li>How to efficiently generate file of given size in Android?
  
  <ul>
  <li>is RandomAccessFile sufficient method? (see <a href="https://stackoverflow.com/questions/245251/create-file-with-given-size-in-java">Create file with given size in Java</a>)</li>
  </ul></li>
  <li>How to efficiently fill the file with random data ?
  
  <ul>
  <li>What is the best source (ideally compatible back to v7) of random bytes?</li>
  <li>Is it necessary, because the file would contain data previously written in allocated harddisk space?</li>
  </ul></li>
  </ul>