What format is that file? turn it into a byte-Array, there might be a function for that already available.
This code does the same with a String:
String strFilePath = "demo.txt";
try {
FileOutputStream oStream = new FileOutputStream(strFilePath);
String strContent = "Write File using Java FileOutputStream example !";
oStream.write(strContent.getBytes());
oStream.close();
}
catch(Exception oException) {
System.out.println("OOOPS : " + oException);
}