| 110 | const Ordering& ordering() const override { return inputs_[0]->ordering(); } |
| 111 | |
| 112 | Status InputFinished(ExecNode* input, int total_batches) override { |
| 113 | DCHECK_EQ(input, inputs_[0]); |
| 114 | EVENT_ON_CURRENT_SPAN("InputFinished", {{"batches.length", total_batches}}); |
| 115 | // Normally we will finish in InputFinished because we sent count_ rows. However, it |
| 116 | // is possible that the input does not contain count_ rows and so we have to end from |
| 117 | // here |
| 118 | if (in_batch_counter_.SetTotal(total_batches)) { |
| 119 | if (!finished_) { |
| 120 | finished_ = true; |
| 121 | ARROW_RETURN_NOT_OK(inputs_[0]->StopProducing()); |
| 122 | ARROW_RETURN_NOT_OK(output_->InputFinished(this, out_batch_count_)); |
| 123 | } |
| 124 | } |
| 125 | return Status::OK(); |
| 126 | } |
| 127 | |
| 128 | Status Validate() const override { |
| 129 | ARROW_RETURN_NOT_OK(ExecNode::Validate()); |
no test coverage detected