See Also: FileOutputStream Members
An output stream that writes bytes to a file. If the output file exists, it can be replaced or appended to. If it does not exist, a new file will be created.
java Example
File file = ...
OutputStream out = null;
try {
out = new BufferedOutputStream(new FileOutputStream(file));
...
finally {
if (out != null) {
out.close();
}
}
}This stream is not buffered. Most callers should wrap this stream with a Java.IO.BufferedOutputStream.
Use Java.IO.FileWriter to write characters, as opposed to bytes, to a file.