FileLockImpl.java: Fixed filename in copyright.

2004-01-23  Michael Koch  <konqueror@gmx.de>

	* gnu/java/nio/FileLockImpl.java:
	Fixed filename in copyright.
	(released): Removed.
	(finalize): New method.
	* gnu/java/nio/natFileLockImpl.cc
	(releaseImpl): Implemented.
	* java/nio/channels/FileChannelImpl.java:
	Reworked imports.
	(lock): Implemented.
	(lockImpl): New method.
	(tryLock): Implemented.
	(tryLockImpl): New method.
	* java/nio/channels/natFileChannelImpl.cc
	(lockImpl): New method.
	(tryLockImpl): New method.

From-SVN: r76422
This commit is contained in:
Michael Koch 2004-01-23 14:37:09 +00:00 committed by Michael Koch
parent ca1d829f31
commit 9719e37cec
5 changed files with 86 additions and 10 deletions

View file

@ -1,5 +1,5 @@
/* FileChannelImpl.java --
Copyright (C) 2002 Free Software Foundation, Inc.
/* FileLockImpl.java --
Copyright (C) 2002, 2004 Free Software Foundation, Inc.
This file is part of GNU Classpath.
@ -60,14 +60,24 @@ public class FileLockImpl extends FileLock
}
private FileDescriptor fd;
private boolean released;
public FileLockImpl (FileDescriptor fd, FileChannel channel, long position,
long size, boolean shared)
{
super (channel, position, size, shared);
this.fd = fd;
this.released = false;
}
public void finalize()
{
try
{
release();
}
catch (IOException e)
{
// Ignore this.
}
}
public boolean isValid ()