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 <functional>
#include <iosfwd>
#include <limits>
#include <userver/dump/fwd.hpp>
#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>
+ This graph shows which files directly or indirectly include this file:

Classes

struct  storages::postgres::TimePointTz
 Corresponds to TIMESTAMP WITH TIME ZONE database type. More...
 
struct  storages::postgres::TimePointWithoutTz
 Corresponds to TIMESTAMP WITHOUT TIME ZONE database type. More...
 
struct  storages::postgres::io::BufferFormatter< TimePointTz >
 Binary formatter for TimePointTz. More...
 
struct  storages::postgres::io::BufferFormatter< TimePointWithoutTz >
 Binary formatter for TimePointWithoutTz. More...
 
struct  storages::postgres::io::BufferParser< TimePointTz >
 Binary parser for TimePointTz. More...
 
struct  storages::postgres::io::BufferParser< TimePointWithoutTz >
 Binary parser for TimePointWithoutTz. More...
 
struct  storages::postgres::io::BufferParser< TimePoint >
 Binary parser for TimePoint. Implicitly converts TimePoint to TimePointWithoutTz. 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< TimePointWithoutTz >
 
struct  storages::postgres::io::CppToSystemPg< std::chrono::time_point< ClockType, Duration > >
 
struct  storages::postgres::io::CppToSystemPg< std::chrono::duration< Rep, Period > >
 
struct  std::hash<::storages::postgres::TimePointTz >
 std::hash support for storages::postgres::TimePointTz. More...
 
struct  std::hash<::storages::postgres::TimePointWithoutTz >
 std::hash support for storages::postgres::TimePointWithoutTz. More...
 

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
 
using storages::postgres::IntervalType = std::chrono::microseconds
 

Functions

logging::LogHelperstorages::postgres::operator<< (logging::LogHelper &, TimePointTz)
 Logging support for TimePointTz.
 
std::ostream & storages::postgres::operator<< (std::ostream &, TimePointTz)
 gtest logging support for TimePointTz.
 
logging::LogHelperstorages::postgres::operator<< (logging::LogHelper &, TimePointWithoutTz)
 Logging support for TimePointWithoutTz.
 
std::ostream & storages::postgres::operator<< (std::ostream &, TimePointWithoutTz)
 gtest logging support for TimePointWithoutTz.
 
TimePointTz storages::postgres::Now ()
 Mockable now that is written as TIMESTAMP WITH TIME ZONE.
 
TimePointWithoutTz storages::postgres::NowWithoutTz ()
 Mockable now that is written as TIMESTAMP WITHOUT TIME ZONE.
 
TimePoint storages::postgres::PostgresEpochTimePoint ()
 Postgres epoch timestamp (2000-01-01 00:00 UTC)
 
void storages::postgres::Write (dump::Writer &writer, const TimePointTz &value)
 Cache dumps support for storages::postgres::TimePointTz.
 
TimePointTz storages::postgres::Read (dump::Reader &reader, dump::To< TimePointTz >)
 
void storages::postgres::Write (dump::Writer &writer, const TimePointWithoutTz &value)
 Cache dumps support for storages::postgres::TimePointWithoutTz.
 
TimePointWithoutTz storages::postgres::Read (dump::Reader &reader, dump::To< TimePointWithoutTz >)
 

Variables

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