blob: cf56fdf10d921d20a6d63d7c44927cc8c68ec9b0 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
#pragma once
#include <Processors/IProcessor.h>
namespace DB
{
/// Transform which has single input and num_outputs outputs.
/// Read chunk from input and copy it to all outputs.
class CopyTransform : public IProcessor
{
public:
CopyTransform(const Block & header, size_t num_outputs);
String getName() const override { return "Copy"; }
Status prepare() override;
InputPort & getInputPort() { return inputs.front(); }
private:
Chunk chunk;
bool has_data = false;
std::vector<char> was_output_processed;
Status prepareGenerate();
Status prepareConsume();
};
}
|