3#ifndef TETL_CHRONO_WEEKDAY_INDEXED_HPP
4#define TETL_CHRONO_WEEKDAY_INDEXED_HPP
22 [[nodiscard]]
constexpr auto index() const noexcept ->
unsigned {
return _index; }
24 [[nodiscard]]
constexpr auto ok() const noexcept ->
bool
26 return weekday().ok() and ((_index >= 1) and (_index <= 5));
31 return lhs.weekday() == rhs.weekday() and lhs.index() == rhs.index();
Definition adjacent_find.hpp:8
TETL_BUILTIN_UINT8 uint8_t
Unsigned integer type with width of exactly 8 bits.
Definition uint_t.hpp:11
Definition weekday_indexed.hpp:11
constexpr auto index() const noexcept -> unsigned
Definition weekday_indexed.hpp:22
constexpr auto ok() const noexcept -> bool
Definition weekday_indexed.hpp:24
constexpr auto weekday() const noexcept -> etl::chrono::weekday
Definition weekday_indexed.hpp:20
weekday_indexed()=default
constexpr weekday_indexed(etl::chrono::weekday const &wd, unsigned index) noexcept
Definition weekday_indexed.hpp:14
friend constexpr auto operator==(weekday_indexed const &lhs, weekday_indexed const &rhs) noexcept -> bool
Definition weekday_indexed.hpp:29
Definition weekday.hpp:18
constexpr auto operator[](unsigned index) const noexcept -> weekday_indexed
Definition weekday_indexed.hpp:39