Default ReadAsync() implementation: simply issue the read on the context's executor
| 164 | |
| 165 | // Default ReadAsync() implementation: simply issue the read on the context's executor |
| 166 | Future<std::shared_ptr<Buffer>> RandomAccessFile::ReadAsync(const IOContext& ctx, |
| 167 | int64_t position, |
| 168 | int64_t nbytes) { |
| 169 | auto self = std::dynamic_pointer_cast<RandomAccessFile>(shared_from_this()); |
| 170 | return DeferNotOk(internal::SubmitIO( |
| 171 | ctx, [self, position, nbytes] { return self->ReadAt(position, nbytes); })); |
| 172 | } |
| 173 | |
| 174 | Future<std::shared_ptr<Buffer>> RandomAccessFile::ReadAsync(int64_t position, |
| 175 | int64_t nbytes) { |
no test coverage detected