proxygen
Conv.h File Reference
#include <chrono>
#include <type_traits>
#include <folly/Conv.h>
#include <folly/Expected.h>
#include <folly/portability/SysTime.h>
#include <folly/portability/SysTypes.h>

Go to the source code of this file.

Classes

struct  folly::detail::is_duration< T >
 
struct  folly::detail::is_duration< std::chrono::duration< Rep, Period > >
 
struct  folly::detail::is_time_point< T >
 
struct  folly::detail::is_time_point< std::chrono::time_point< Clock, Duration > >
 
struct  folly::detail::is_std_chrono_type< T >
 
struct  folly::detail::is_posix_time_type< T >
 
struct  folly::detail::is_chrono_conversion< Tgt, Src >
 
struct  folly::detail::IntermediateTimeRep< T, IsFloatingPoint, IsSigned >
 
struct  folly::detail::IntermediateTimeRep< T, true, IsSigned >
 
struct  folly::detail::IntermediateTimeRep< T, false, true >
 
struct  folly::detail::IntermediateTimeRep< T, false, false >
 
struct  folly::detail::CheckOverflowToDuration< IsFloatingPoint >
 
struct  folly::detail::CheckOverflowToDuration< true >
 

Namespaces

 folly
 —— Concurrent Priority Queue Implementation ——
 
 folly::detail
 

Typedefs

template<typename Rep , typename Period >
using folly::detail::IntermediateDuration = std::chrono::duration< typename IntermediateTimeRep< Rep, std::is_floating_point< Rep >::value, std::is_signed< Rep >::value >::type, std::ratio< 1, Period::den >>
 

Functions

template<typename Src >
Expected< time_t, ConversionCode > folly::detail::chronoRangeCheck (Src value)
 
template<typename SubsecondRatio , typename Rep >
static Expected< std::pair< time_t, long >, ConversionCode > folly::detail::durationToPosixTime (const std::chrono::duration< Rep, std::ratio< 1, 1 >> &duration)
 
template<typename SubsecondRatio , typename Rep , std::intmax_t Denominator>
static Expected< std::pair< time_t, long >, ConversionCode > folly::detail::durationToPosixTime (const std::chrono::duration< Rep, std::ratio< 1, Denominator >> &duration)
 
template<typename SubsecondRatio , typename Rep , std::intmax_t Numerator>
static Expected< std::pair< time_t, long >, ConversionCode > folly::detail::durationToPosixTime (const std::chrono::duration< Rep, std::ratio< Numerator, 1 >> &duration)
 
template<typename SubsecondRatio , typename Rep , typename Period >
Expected< std::pair< time_t, long >, ConversionCode > folly::detail::durationToPosixTime (const std::chrono::duration< Rep, Period > &duration)
 
template<typename SubsecondRatio , typename Seconds , typename Subseconds , typename Rep >
auto folly::detail::posixTimeToDuration (Seconds seconds, Subseconds subseconds, std::chrono::duration< Rep, std::ratio< 1, 1 >> dummy) -> Expected< decltype(dummy), ConversionCode >
 
template<typename SubsecondRatio , typename Seconds , typename Subseconds , typename Rep , std::intmax_t Denominator>
auto folly::detail::posixTimeToDuration (Seconds seconds, Subseconds subseconds, std::chrono::duration< Rep, std::ratio< 1, Denominator >> dummy) -> Expected< decltype(dummy), ConversionCode >
 
template<typename SubsecondRatio , typename Seconds , typename Subseconds , typename Rep , std::intmax_t Numerator>
auto folly::detail::posixTimeToDuration (Seconds seconds, Subseconds subseconds, std::chrono::duration< Rep, std::ratio< Numerator, 1 >> dummy) -> Expected< decltype(dummy), ConversionCode >
 
template<typename SubsecondRatio , typename Seconds , typename Subseconds , typename Rep , std::intmax_t Denominator, std::intmax_t Numerator>
auto folly::detail::posixTimeToDuration (Seconds seconds, Subseconds subseconds, std::chrono::duration< Rep, std::ratio< Numerator, Denominator >> dummy) -> Expected< decltype(dummy), ConversionCode >
 
template<typename Tgt , typename SubsecondRatio , typename Seconds , typename Subseconds >
Expected< Tgt, ConversionCode > folly::detail::tryPosixTimeToDuration (Seconds seconds, Subseconds subseconds)
 
template<typename Tgt >
std::enable_if< detail::is_duration< Tgt >::value, Expected< Tgt, ConversionCode > >::type folly::tryTo (const struct timespec &ts)
 
template<typename Tgt >
std::enable_if< detail::is_duration< Tgt >::value, Expected< Tgt, ConversionCode > >::type folly::tryTo (const struct timeval &tv)
 
template<typename Tgt , typename Src >
std::enable_if< detail::is_time_point< Tgt >::value &&detail::is_posix_time_type< Src >::value, Expected< Tgt, ConversionCode > >::type folly::tryTo (const Src &value)
 
template<typename Tgt , typename Rep , typename Period >
std::enable_if< std::is_same< Tgt, struct timespec >::value, Expected< Tgt, ConversionCode > >::type folly::tryTo (const std::chrono::duration< Rep, Period > &duration)
 
template<typename Tgt , typename Rep , typename Period >
std::enable_if< std::is_same< Tgt, struct timeval >::value, Expected< Tgt, ConversionCode > >::type folly::tryTo (const std::chrono::duration< Rep, Period > &duration)
 
template<typename Tgt , typename Clock , typename Duration >
std::enable_if< detail::is_posix_time_type< Tgt >::value, Expected< Tgt, ConversionCode > >::type folly::tryTo (const std::chrono::time_point< Clock, Duration > &timePoint)
 
template<typename Tgt , typename Src >
std::enable_if< detail::is_chrono_conversion< Tgt, Src >::value, Tgt >::type folly::to (const Src &value)