DthingApi
|
Public Member Functions | |
FileOutputStream (File file) throws FileNotFoundException | |
FileOutputStream (File file, boolean append) throws FileNotFoundException | |
FileOutputStream (FileDescriptor fd) | |
FileOutputStream (String path) throws FileNotFoundException | |
FileOutputStream (String path, boolean append) throws FileNotFoundException | |
void | close () throws IOException |
void | flush () throws IOException |
final FileDescriptor | getFD () throws IOException |
void | write (byte[] buffer, int byteOffset, int byteCount) throws IOException |
void | write (byte[] buffer) throws IOException |
void | write (int oneByte) throws IOException |
![]() | |
OutputStream () | |
void | close () throws IOException |
void | flush () throws IOException |
void | write (byte[] buffer) throws IOException |
void | write (byte[] buffer, int offset, int count) throws IOException |
abstract void | write (int oneByte) throws IOException |
Protected Member Functions | |
void | finalize () throws IOException |
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.
File file = ...OutputStream out = null;try {...} finally {if (out != null) {out.close();}}
This stream is not buffered. Most callers should wrap this stream with a BufferedOutputStream.
Use FileWriter to write characters, as opposed to bytes, to a file.
|
inline |
Constructs a new
that writes to
. The file will be truncated if it exists, and created if it doesn't exist.
FileNotFoundException | if file cannot be opened for writing. |
|
inline |
Constructs a new
that writes to
. If
is true and the file already exists, it will be appended to; otherwise it will be truncated. The file will be created if it does not exist.
FileNotFoundException | if the file cannot be opened for writing. |
|
inline |
|
inline |
Constructs a new
that writes to
. The file will be truncated if it exists, and created if it doesn't exist.
FileNotFoundException | if file cannot be opened for writing. |
|
inline |
Constructs a new
that writes to
. If
is true and the file already exists, it will be appended to; otherwise it will be truncated. The file will be created if it does not exist.
FileNotFoundException | if the file cannot be opened for writing. |
|
inline |
Returns the underlying file descriptor.