| 169 | } |
| 170 | |
| 171 | void Put(const ByteArray& val) { |
| 172 | // Write the result to the output stream |
| 173 | const int64_t increment = static_cast<int64_t>(val.len + sizeof(uint32_t)); |
| 174 | if (ARROW_PREDICT_FALSE(sink_.length() + increment > sink_.capacity())) { |
| 175 | PARQUET_THROW_NOT_OK(sink_.Reserve(increment)); |
| 176 | } |
| 177 | UnsafePutByteArray(val.ptr, val.len); |
| 178 | } |
| 179 | |
| 180 | protected: |
| 181 | template <typename ArrayType> |