-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Expand file tree
/
Copy pathAggregateDescription.h
More file actions
35 lines (25 loc) · 1.04 KB
/
AggregateDescription.h
File metadata and controls
35 lines (25 loc) · 1.04 KB
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
32
33
34
35
#pragma once
#include <AggregateFunctions/IAggregateFunction_fwd.h>
#include <Core/ColumnNumbers.h>
#include <Core/Field.h>
#include <Core/Names.h>
#include <Core/Types.h>
namespace DB
{
class WriteBuffer;
struct ExplainFormatSettings;
namespace JSONBuilder { class JSONMap; }
struct AggregateDescription
{
AggregateFunctionPtr function;
Array parameters; /// Parameters of the (parametric) aggregate function.
Names argument_names;
String column_name; /// What name to use for a column with aggregate function values
void explain(WriteBuffer & out, const std::string & prefix, size_t additonal_indent) const; /// Get description for EXPLAIN query.
void explain(JSONBuilder::JSONMap & map) const;
void explainPretty(ExplainFormatSettings & settings) const;
};
using AggregateDescriptions = std::vector<AggregateDescription>;
void serializeAggregateDescriptions(const AggregateDescriptions & aggregates, WriteBuffer & out);
void deserializeAggregateDescriptions(AggregateDescriptions & aggregates, ReadBuffer & in);
}