ClickHouse/src/Processors/Formats/Impl/NullFormat.cpp

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

24 lines
490 B
C++
Raw Normal View History

2021-10-13 10:01:08 +00:00
#include <Processors/Formats/Impl/NullFormat.h>
2019-02-19 18:41:18 +00:00
#include <Formats/FormatFactory.h>
2021-10-13 10:01:08 +00:00
#include <IO/WriteBuffer.h>
2019-02-19 18:41:18 +00:00
namespace DB
{
2021-10-13 10:01:08 +00:00
WriteBuffer NullOutputFormat::empty_buffer(nullptr, 0);
2019-02-19 18:41:18 +00:00
2021-10-11 16:11:50 +00:00
void registerOutputFormatNull(FormatFactory & factory)
2019-02-19 18:41:18 +00:00
{
2021-10-11 16:11:50 +00:00
factory.registerOutputFormat("Null", [](
2021-10-13 10:01:08 +00:00
WriteBuffer &,
2019-02-19 18:41:18 +00:00
const Block & sample,
const RowOutputFormatParams &,
2019-02-19 18:41:18 +00:00
const FormatSettings &)
{
2021-10-13 10:01:08 +00:00
return std::make_shared<NullOutputFormat>(sample);
2019-02-19 18:41:18 +00:00
});
}
}