|
JavaTM 2 Platform Std. Ed. v1.4.0 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.io.FileDescriptor
Instances of the file descriptor class serve as an opaque handle
to the underlying machine-specific structure representing an open
file, an open socket, or another source or sink of bytes. The
main practical use for a file descriptor is to create a
FileInputStream
or FileOutputStream
to
contain it.
Applications should not create their own file descriptors.
FileInputStream
,
FileOutputStream
Field Summary | |
static FileDescriptor |
err
A handle to the standard error stream. |
static FileDescriptor |
in
A handle to the standard input stream. |
static FileDescriptor |
out
A handle to the standard output stream. |
Constructor Summary | |
FileDescriptor()
Constructs an (invalid) FileDescriptor object. |
Method Summary | |
void |
sync()
Force all system buffers to synchronize with the underlying device. |
boolean |
valid()
Tests if this file descriptor object is valid. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final FileDescriptor in
System.in
.
System.in
public static final FileDescriptor out
System.out
.
System.out
public static final FileDescriptor err
System.err
.
System.err
Constructor Detail |
public FileDescriptor()
Method Detail |
public boolean valid()
true
if the file descriptor object represents a
valid, open file, socket, or other active I/O connection;
false
otherwise.public void sync() throws SyncFailedException
SyncFailedException
- Thrown when the buffers cannot be flushed,
or because the system cannot guarantee that all the
buffers have been synchronized with physical media.
|
JavaTM 2 Platform Std. Ed. v1.4.0 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Java, Java 2D, and JDBC are trademarks or registered trademarks of Sun Microsystems, Inc. in the US and other countries.
Copyright 1993-2002 Sun Microsystems, Inc. 901 San Antonio Road
Palo Alto, California, 94303, U.S.A. All Rights Reserved.