public final class BlockMgrFileAccess extends BlockMgrBase
| Modifier and Type | Method and Description |
|---|---|
long |
allocLimit()
The fixed allocated blocks are in the range [0,allocLimit).
|
void |
close()
Close the block manager
|
void |
free(Block block)
Announce a block is no longer in use (i.e it's now freed)
|
Block |
getRead(long id)
Fetch a block, use for read only
|
Block |
getWrite(long id)
Fetch a block, use for write and read - only inside "update"
|
boolean |
isClosed()
Is this block manager still usable? Closed block managers can not perform any operations except this one.
|
boolean |
isEmpty()
Answer whether there are any blocks in the collection being managed
|
void |
overwrite(Block block)
Replace the contents of a block slot with new contents.
|
Block |
promote(Block block)
Promote to writable : it's OK to promote an already writable block
|
void |
release(Block block)
Release a block, unmodified or already written.
|
void |
resetAlloc(long boundary)
Reset the allocation limit, should be a number previously obtained from allocLimit
|
void |
sync()
Sync the block manager
|
void |
syncForce()
Sync the block manager : system operation to ensure sync() is passed down
|
String |
toString() |
boolean |
valid(int id)
Is this a valid block id? (may be a free block)
|
void |
write(Block block)
Write a block back - it still needs releasing.
|
allocate, beginRead, beginUpdate, endRead, endUpdate, getLabelpublic Block promote(Block block)
BlockMgrpublic Block getRead(long id)
BlockMgrpublic Block getWrite(long id)
BlockMgrpublic void release(Block block)
BlockMgrpublic void write(Block block)
BlockMgrpublic void overwrite(Block block)
BlockMgrpublic void free(Block block)
BlockMgrpublic boolean valid(int id)
BlockMgrpublic void sync()
BlockMgrpublic void syncForce()
BlockMgrpublic boolean isClosed()
BlockMgrpublic void close()
BlockMgrpublic boolean isEmpty()
BlockMgrpublic long allocLimit()
BlockMgrpublic void resetAlloc(long boundary)
BlockMgrLicensed under the Apache License, Version 2.0