Used for vectors of type VARCHAR and VARBINARY to replace the old data buffers with 'buffers' which are referenced by StringView's.
| 485 | /// Used for vectors of type VARCHAR and VARBINARY to replace the old data |
| 486 | /// buffers with 'buffers' which are referenced by StringView's. |
| 487 | void setStringBuffers(std::vector<BufferPtr> buffers) { |
| 488 | BOLT_DCHECK_GE(stringBuffers_.size(), stringBufferSet_.size()); |
| 489 | |
| 490 | stringBuffers_ = std::move(buffers); |
| 491 | stringBufferSet_.clear(); |
| 492 | stringBufferSet_.reserve(stringBuffers_.size()); |
| 493 | for (const auto& bufferPtr : stringBuffers_) { |
| 494 | stringBufferSet_.insert(bufferPtr.get()); |
| 495 | } |
| 496 | } |
| 497 | |
| 498 | /// Used for vectors of type VARCHAR and VARBINARY to release the data |
| 499 | /// buffers referenced by StringView's. |