17#if defined(__cpp_lib_format)
57 L* p_layout =
nullptr;
59#if defined(__cpp_lib_format)
60 friend std::formatter<timestamp_reference<L>>;
67 template <
typename Layout,
typename T,
template <
typename>
typename TQual,
template <
typename>
typename UQual>
73 template <
typename Layout,
typename T,
template <
typename>
typename TQual,
template <
class>
class UQual>
96 p_layout->assign(std::forward<value_type>(rhs), m_index);
100 template <
typename L>
103 p_layout->assign(rhs, m_index);
107 template <
typename L>
110 return value() == rhs;
113 template <
typename L>
116 return lexicographical_compare_three_way(*
this, rhs);
119 template <
typename L>
122 return static_cast<const L*
>(p_layout)->
value(m_index);
126#if defined(__cpp_lib_format)
129struct std::formatter<
sparrow::timestamp_reference<L>>
131 constexpr auto parse(std::format_parse_context& ctx)
136 auto format(
const sparrow::timestamp_reference<L>& ref, std::format_context& ctx)
const
138 const auto& value = ref.
value();
139 return std::format_to(ctx.out(),
"{}", value);
146 os << std::format(
"{}", value);
Implementation of reference to inner type used for layout L.
timestamp_reference(L *layout, size_type index)
const_reference value() const
std::ptrdiff_t difference_type
timestamp_reference< self_type > self_type
bool operator==(const value_type &rhs) const
typename self_type::inner_value_type value_type
timestamp_reference(timestamp_reference &&) noexcept=default
typename self_type::size_type size_type
typename self_type::inner_reference reference
timestamp_reference(const timestamp_reference &)=default
auto operator<=>(const value_type &rhs) const
typename self_type::inner_const_reference const_reference
self_type & operator=(value_type &&rhs)
date::zoned_time< Duration, TimeZonePtr > timestamp
std::ostream & operator<<(std::ostream &os, const sparrow::nullval_t &)