ClickHouse/src/DataStreams/NullBlockOutputStream.h

23 lines
402 B
C++
Raw Normal View History

2012-05-08 11:19:00 +00:00
#pragma once
#include <DataStreams/IBlockOutputStream.h>
2012-05-08 11:19:00 +00:00
namespace DB
{
2017-05-13 22:19:04 +00:00
/** Does nothing. Used for debugging and benchmarks.
2012-05-08 11:19:00 +00:00
*/
class NullBlockOutputStream : public IBlockOutputStream
{
public:
2019-08-03 11:02:40 +00:00
NullBlockOutputStream(const Block & header_) : header(header_) {}
Block getHeader() const override { return header; }
2017-12-01 19:34:51 +00:00
void write(const Block &) override {}
private:
Block header;
2012-05-08 11:19:00 +00:00
};
}