@InterfaceAudience.Private public class SharedMemoryMmapIOEngine extends FileMmapIOEngine
MemoryType#SHARED type when serving the
data from this pmem address space. We need not copy the blocks to the onheap space as we need to
do for the case of ExclusiveMemoryMmapIOEngine.bufferArray, path, size| 构造器和说明 |
|---|
SharedMemoryMmapIOEngine(String filePath,
long capacity) |
| 限定符和类型 | 方法和说明 |
|---|---|
Cacheable |
read(long offset,
int length,
CacheableDeserializer<Cacheable> deserializer)
Transfers data from IOEngine to a Cacheable object.
|
boolean |
usesSharedMemory()
IOEngine uses shared memory means, when reading Cacheable from it, those refers to the same
memory area as used by the Engine for caching it.
|
isPersistent, shutdown, sync, toString, write, writepublic SharedMemoryMmapIOEngine(String filePath, long capacity) throws IOException
IOExceptionpublic boolean usesSharedMemory()
IOEnginepublic Cacheable read(long offset, int length, CacheableDeserializer<Cacheable> deserializer) throws IOException
IOEngineread 在接口中 IOEngineread 在类中 FileMmapIOEngineoffset - The offset in the IO engine where the first byte to be readlength - How many bytes to be read from the offsetdeserializer - The deserializer to be used to make a Cacheable from the data.IOExceptionCopyright © 2007–2020 The Apache Software Foundation. All rights reserved.