| 122 | } |
| 123 | |
| 124 | ::arrow::Status Write(const void* data, int64_t nbytes) override { |
| 125 | if (closed_) |
| 126 | return ::arrow::Status::IOError("write on closed"); |
| 127 | if (nbytes <= 0) |
| 128 | return ::arrow::Status::OK(); |
| 129 | out_->write( |
| 130 | reinterpret_cast<const char*>(data), |
| 131 | static_cast<std::streamsize>(nbytes)); |
| 132 | return ::arrow::Status::OK(); |
| 133 | } |
| 134 | |
| 135 | ::arrow::Status Write(const std::shared_ptr<::arrow::Buffer>& buf) override { |
| 136 | return Write(buf->data(), buf->size()); |
no test coverage detected