userver: userver/storages/clickhouse/io/columns/datetime_column.hpp Source File
Loading...
Searching...
No Matches
datetime_column.hpp
Go to the documentation of this file.
1#pragma once
2
3/// @file userver/storages/clickhouse/io/columns/datetime_column.hpp
4/// @brief DateTime column support
5/// @ingroup userver_clickhouse_types
6
7#include <chrono>
8
9#include <userver/storages/clickhouse/io/columns/column_includes.hpp>
10
11USERVER_NAMESPACE_BEGIN
12
13namespace storages::clickhouse::io::columns {
14
15/// @brief Represents ClickHouse DateTime column
16class DateTimeColumn final : public ClickhouseColumn<DateTimeColumn> {
17 public:
18 using cpp_type = std::chrono::system_clock::time_point;
19 using container_type = std::vector<cpp_type>;
20
21 DateTimeColumn(ColumnRef column);
22
23 static ColumnRef Serialize(const container_type& from);
24};
25
26} // namespace storages::clickhouse::io::columns
27
28USERVER_NAMESPACE_END