| 1575 | }; |
| 1576 | |
| 1577 | AsofJoinNode::AsofJoinNode(ExecPlan* plan, NodeVector inputs, |
| 1578 | std::vector<std::string> input_labels, |
| 1579 | const std::vector<col_index_t>& indices_of_on_key, |
| 1580 | const std::vector<std::vector<col_index_t>>& indices_of_by_key, |
| 1581 | AsofJoinNodeOptions join_options, |
| 1582 | std::shared_ptr<Schema> output_schema, |
| 1583 | std::vector<std::unique_ptr<KeyHasher>> key_hashers, |
| 1584 | bool must_hash, bool may_rehash) |
| 1585 | : ExecNode(plan, inputs, input_labels, |
| 1586 | /*output_schema=*/std::move(output_schema)), |
| 1587 | ordering_({SortKey(indices_of_on_key[0])}), |
| 1588 | indices_of_on_key_(std::move(indices_of_on_key)), |
| 1589 | indices_of_by_key_(std::move(indices_of_by_key)), |
| 1590 | key_hashers_(std::move(key_hashers)), |
| 1591 | must_hash_(must_hash), |
| 1592 | may_rehash_(may_rehash), |
| 1593 | tolerance_(TolType(join_options.tolerance)), |
| 1594 | #ifndef NDEBUG |
| 1595 | debug_os_(join_options.debug_opts ? join_options.debug_opts->os : nullptr), |
| 1596 | debug_mutex_(join_options.debug_opts ? join_options.debug_opts->mutex : nullptr), |
| 1597 | #endif |
| 1598 | backpressure_counter_(1) |
| 1599 | #ifdef ARROW_ENABLE_THREADING |
| 1600 | , |
| 1601 | process_(), |
| 1602 | process_thread_() |
| 1603 | #endif |
| 1604 | { |
| 1605 | for (auto& key_hasher : key_hashers_) { |
| 1606 | key_hasher->node_ = this; |
| 1607 | } |
| 1608 | } |
| 1609 | |
| 1610 | namespace internal { |
| 1611 | void RegisterAsofJoinNode(ExecFactoryRegistry* registry) { |