|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.entityfs.util.base.AbstractWritableFile
public abstract class AbstractWritableFile
This class can be used as a starting point for WritableFile
implementations.
Constructor Summary | |
---|---|
AbstractWritableFile()
|
Method Summary | |
---|---|
EntityLock |
getWriteLock()
This method returns a NoObjectDummyLock . |
boolean |
isWriteLockedByCurrentThread()
This method always returns true . |
EntityLock |
lockForWriting()
This method returns a NoObjectDummyLock . |
WritableByteChannel |
openChannelForAppend()
This method opens a byte channel on the OutputStream returned
from openForAppend . |
WritableByteChannel |
openChannelForWrite()
This method opens a byte channel on the OutputStream returned
from openForWrite . |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.entityfs.WritableFile |
---|
openForAppend, openForWrite |
Constructor Detail |
---|
public AbstractWritableFile()
Method Detail |
---|
public EntityLock getWriteLock()
NoObjectDummyLock
.
getWriteLock
in interface WriteLockable
public EntityLock lockForWriting()
NoObjectDummyLock
.
lockForWriting
in interface WriteLockable
public boolean isWriteLockedByCurrentThread()
true
. Override it to change that
behavior.
isWriteLockedByCurrentThread
in interface WriteLockable
true
, always.public WritableByteChannel openChannelForAppend()
OutputStream
returned
from openForAppend
.
openChannelForAppend
in interface WritableFile
WritableByteChannel
. The channel must be closed
by the caller. The returned channel may be a
GatheringByteChannel
, but that is not required.public WritableByteChannel openChannelForWrite()
OutputStream
returned
from openForWrite
.
openChannelForWrite
in interface WritableFile
WritableByteChannel
. The channel must be closed
by the caller. The returned channel may be a
GatheringByteChannel
, but that is not required.WritableFile.openForWrite()
,
WritableFile.openChannelForAppend()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |