userver: userver/storages/postgres/io/chrono.hpp File Reference
Loading...
Searching...
No Matches
chrono.hpp File Reference

Detailed Description

Timestamp (std::chrono::*) I/O support.

Definition in file chrono.hpp.

Go to the source code of this file.

#include <chrono>
#include <limits>
#include <userver/storages/postgres/io/buffer_io.hpp>
#include <userver/storages/postgres/io/buffer_io_base.hpp>
#include <userver/storages/postgres/io/interval.hpp>
#include <userver/storages/postgres/io/transform_io.hpp>
#include <userver/storages/postgres/io/type_mapping.hpp>
#include <userver/utils/strong_typedef.hpp>
+ Include dependency graph for chrono.hpp:
+ This graph shows which files directly or indirectly include this file:

Classes

struct  storages::postgres::io::BufferFormatter< std::chrono::time_point< ClockType, Duration > >
 Binary formatter for std::chrono::time_point. More...
 
struct  storages::postgres::io::BufferParser< std::chrono::time_point< ClockType, Duration > >
 Binary parser for std::chrono::time_point. More...
 
struct  storages::postgres::io::traits::Output< std::chrono::duration< Rep, Period > >
 Binary formatter for std::chrono::duration. More...
 
struct  storages::postgres::io::traits::Input< std::chrono::duration< Rep, Period > >
 Binary parser for std::chrono::duration. More...
 
struct  storages::postgres::io::CppToSystemPg< TimePointTz >
 
struct  storages::postgres::io::CppToSystemPg< std::chrono::time_point< ClockType, Duration > >
 
struct  storages::postgres::io::CppToSystemPg< std::chrono::duration< Rep, Period > >
 

Namespaces

namespace  storages
 Components, clients and helpers for different databases and storages.
 
namespace  storages::postgres
 Top namespace for uPg driver.
 
namespace  storages::postgres::io
 uPg input-output.
 
namespace  storages::postgres::io::traits
 uPg input-output traits.
 

Typedefs

using storages::postgres::ClockType = std::chrono::system_clock
 
using storages::postgres::TimePoint = ClockType::time_point
 Corresponds to TIMESTAMP WITHOUT TIME ZONE (value in absolute time (no TZ offset)).
 
using storages::postgres::TimePointTz
 Corresponds to TIMESTAMP WITH TIME ZONE (value in absolute time (no TZ offset)). Time zones are applied automatically.
 
using storages::postgres::IntervalType = std::chrono::microseconds
 

Functions

TimePoint storages::postgres::PostgresEpochTimePoint ()
 Postgres epoch timestamp (2000-01-01 00:00 UTC)
 

Variables

constexpr TimePoint storages::postgres::kTimestampPositiveInfinity = TimePoint::max()
 
constexpr TimePoint storages::postgres::kTimestampNegativeInfinity = TimePoint::min()