| 478 | } |
| 479 | |
| 480 | void NodeTable::initUpdateState(main::ClientContext* context, TableUpdateState& updateState) const { |
| 481 | auto& nodeUpdateState = updateState.cast<NodeTableUpdateState>(); |
| 482 | nodeUpdateState.indexUpdateState.resize(indexes.size()); |
| 483 | for (auto i = 0u; i < indexes.size(); i++) { |
| 484 | auto& indexHolder = indexes[i]; |
| 485 | auto index = indexHolder.getIndex(); |
| 486 | if (index->isPrimary() || !index->isBuiltOnColumn(nodeUpdateState.columnID)) { |
| 487 | nodeUpdateState.indexUpdateState[i] = nullptr; |
| 488 | continue; |
| 489 | } |
| 490 | nodeUpdateState.indexUpdateState[i] = |
| 491 | index->initUpdateState(context, nodeUpdateState.columnID, [&](offset_t offset) { |
| 492 | return isVisible(transaction::Transaction::Get(*context), offset); |
| 493 | }); |
| 494 | } |
| 495 | } |
| 496 | |
| 497 | void NodeTable::update(Transaction* transaction, TableUpdateState& updateState) { |
| 498 | // NOTE: We assume all inputs are flattened now. This is to simplify the implementation. |
nothing calls this directly
no test coverage detected