| 程序包 | 说明 |
|---|---|
| com.alipay.sofa.jraft.storage.io | |
| com.alipay.sofa.jraft.storage.snapshot.local | |
| com.alipay.sofa.jraft.storage.snapshot.remote | |
| com.alipay.sofa.jraft.util |
| 限定符和类型 | 方法和说明 |
|---|---|
int |
FileReader.readFile(ByteBufferCollector buf,
String fileName,
long offset,
long maxCount)
Read file into buf starts from offset at most maxCount.
|
int |
LocalDirReader.readFile(ByteBufferCollector buf,
String fileName,
long offset,
long maxCount) |
protected int |
LocalDirReader.readFileWithMeta(ByteBufferCollector buf,
String fileName,
com.google.protobuf.Message fileMeta,
long offset,
long maxCount) |
| 限定符和类型 | 方法和说明 |
|---|---|
int |
SnapshotFileReader.readFile(ByteBufferCollector metaBufferCollector,
String fileName,
long offset,
long maxCount) |
| 限定符和类型 | 方法和说明 |
|---|---|
boolean |
RemoteFileCopier.copy2IoBuffer(String source,
ByteBufferCollector destBuf,
CopyOptions opt)
Copy `source` from remote to buffer.
|
void |
CopySession.setDestBuf(ByteBufferCollector bufRef) |
Session |
RemoteFileCopier.startCopy2IoBuffer(String source,
ByteBufferCollector destBuf,
CopyOptions opts) |
| 限定符和类型 | 方法和说明 |
|---|---|
ByteBufferCollector |
AdaptiveBufAllocator.Handle.allocate()
Creates a new buffer whose capacity is probably large enough to write all outbound data and small
enough not to waste its space.
|
static ByteBufferCollector |
ByteBufferCollector.allocate() |
static ByteBufferCollector |
ByteBufferCollector.allocate(int size) |
ByteBufferCollector |
AdaptiveBufAllocator.Handle.allocateByRecyclers()
Gets a buffer from recyclers whose capacity is probably large enough to write all outbound data and
small enough not to waste its space, recycling is needed.
|
static ByteBufferCollector |
ByteBufferCollector.allocateByRecyclers() |
static ByteBufferCollector |
ByteBufferCollector.allocateByRecyclers(int size) |
Copyright © 2021. All rights reserved.