blob: f5fd55530b99c5b6f3cd02955e7b4ab98f4170f5 (
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
29
30
31
|
#pragma once
#include <Processors/Formats/IRowOutputFormat.h>
#include <Core/Block.h>
#include <Core/PostgreSQLProtocol.h>
#include <Formats/FormatSettings.h>
namespace DB
{
//// https://www.postgresql.org/docs/current/protocol-flow.html#id-1.10.5.7.4
class PostgreSQLOutputFormat final : public IOutputFormat
{
public:
PostgreSQLOutputFormat(WriteBuffer & out_, const Block & header_, const FormatSettings & settings_);
String getName() const override {return "PostgreSQLOutputFormat";}
void flush() override;
private:
void writePrefix() override;
void consume(Chunk) override;
FormatSettings format_settings;
PostgreSQLProtocol::Messaging::MessageTransport message_transport;
Serializations serializations;
};
}
|