public class MappedFile extends Object implements net.openhft.chronicle.core.ReferenceCounted
Modifier and Type | Method and Description |
---|---|
Bytes |
acquireBytesForRead(long position)
Convenience method so you don't need to release the BytesStore
|
void |
acquireBytesForRead(long position,
VanillaBytes bytes) |
Bytes |
acquireBytesForWrite(long position) |
void |
acquireBytesForWrite(long position,
VanillaBytes bytes) |
MappedBytesStore |
acquireByteStore(long position) |
long |
capacity() |
void |
close() |
static MappedFile |
mappedFile(File file,
long chunkSize) |
static MappedFile |
mappedFile(File file,
long chunkSize,
long overlapSize) |
static MappedFile |
mappedFile(String filename,
long chunkSize) |
static MappedFile |
mappedFile(String filename,
long chunkSize,
long overlapSize) |
long |
refCount() |
String |
referenceCounts() |
void |
release() |
void |
reserve() |
public static MappedFile mappedFile(File file, long chunkSize) throws FileNotFoundException
FileNotFoundException
public static MappedFile mappedFile(String filename, long chunkSize) throws FileNotFoundException
FileNotFoundException
public static MappedFile mappedFile(String filename, long chunkSize, long overlapSize) throws FileNotFoundException
FileNotFoundException
public static MappedFile mappedFile(File file, long chunkSize, long overlapSize) throws FileNotFoundException
FileNotFoundException
public MappedBytesStore acquireByteStore(long position) throws IOException
IOException
public Bytes acquireBytesForRead(long position) throws IOException
IOException
public void acquireBytesForRead(long position, VanillaBytes bytes) throws IOException
IOException
public Bytes acquireBytesForWrite(long position) throws IOException
IOException
public void acquireBytesForWrite(long position, VanillaBytes bytes) throws IOException
IOException
public void reserve()
reserve
in interface net.openhft.chronicle.core.ReferenceCounted
public void release()
release
in interface net.openhft.chronicle.core.ReferenceCounted
public long refCount()
refCount
in interface net.openhft.chronicle.core.ReferenceCounted
public void close()
close
in interface Closeable
close
in interface AutoCloseable
close
in interface net.openhft.chronicle.core.ReferenceCounted
public String referenceCounts()
public long capacity()
Copyright © 2015. All rights reserved.