| 113 | uint64_t getNaturalReadSize() const override { return 128 * 1024; } |
| 114 | |
| 115 | void read(void* buf, uint64_t length, uint64_t offset) override { |
| 116 | ORC_ASSIGN_OR_THROW(int64_t bytes_read, file_->ReadAt(offset, length, buf)); |
| 117 | |
| 118 | if (static_cast<uint64_t>(bytes_read) != length) { |
| 119 | throw liborc::ParseError("Short read from arrow input file"); |
| 120 | } |
| 121 | } |
| 122 | |
| 123 | const std::string& getName() const override { |
| 124 | static const std::string filename("ArrowInputFile"); |