2016-06-07 08:23:15 +00:00
|
|
|
#pragma once
|
|
|
|
|
2017-04-01 09:19:00 +00:00
|
|
|
#include <DataStreams/IBlockInputStream.h>
|
2016-06-07 08:23:15 +00:00
|
|
|
|
|
|
|
|
|
|
|
namespace DB
|
|
|
|
{
|
|
|
|
|
2019-01-23 14:48:50 +00:00
|
|
|
/// Empty stream of blocks of specified structure.
|
2016-06-07 08:23:15 +00:00
|
|
|
class NullBlockInputStream : public IBlockInputStream
|
|
|
|
{
|
|
|
|
public:
|
2019-01-23 14:48:50 +00:00
|
|
|
NullBlockInputStream(const Block & header_) : header(header_) {}
|
2018-01-06 18:10:44 +00:00
|
|
|
|
2018-02-18 03:23:48 +00:00
|
|
|
Block getHeader() const override { return header; }
|
2017-04-01 07:20:54 +00:00
|
|
|
String getName() const override { return "Null"; }
|
2016-06-07 08:23:15 +00:00
|
|
|
|
2018-01-06 18:10:44 +00:00
|
|
|
private:
|
|
|
|
Block header;
|
2019-01-23 14:48:50 +00:00
|
|
|
|
|
|
|
Block readImpl() override { return {}; }
|
2016-06-07 08:23:15 +00:00
|
|
|
};
|
|
|
|
|
2019-01-23 14:48:50 +00:00
|
|
|
} /// namespace DB
|