2004-07-17 Michael Koch <konqueror@gmx.de>
* gnu/java/nio/channels/FileChannelImpl.java (finalize): Added javadoc. From-SVN: r84858
This commit is contained in:
parent
61ce29b17f
commit
2ccc5a9508
2 changed files with 13 additions and 5 deletions
|
@ -115,11 +115,6 @@ public final class FileChannelImpl extends FileChannel
|
|||
this.mode = mode;
|
||||
}
|
||||
|
||||
protected void finalize() throws Throwable
|
||||
{
|
||||
close();
|
||||
}
|
||||
|
||||
public static FileChannelImpl in;
|
||||
public static FileChannelImpl out;
|
||||
public static FileChannelImpl err;
|
||||
|
@ -137,6 +132,14 @@ public final class FileChannelImpl extends FileChannel
|
|||
|
||||
protected native void implCloseChannel() throws IOException;
|
||||
|
||||
/**
|
||||
* Makes sure the Channel is properly closed.
|
||||
*/
|
||||
protected void finalize() throws IOException
|
||||
{
|
||||
this.close();
|
||||
}
|
||||
|
||||
public int read (ByteBuffer dst) throws IOException
|
||||
{
|
||||
int result;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue