weekday_indexed
A class representing an indexed weekday.
class weekday_indexedConstruction
ETL_CONSTEXPR
weekday_indexed()
ETL_NOEXCEPTDescription
Default constructor.
ETL_CONSTEXPR14
weekday_indexed(const etl::chrono::weekday& wd, unsigned index)
ETL_NOEXCEPTDescription
Construct from weekday and index.
ETL_CONSTEXPR14
weekday_indexed(const etl::chrono::weekday_indexed& other)
ETL_NOEXCEPTDescription
Copy constructor.
Tests
ETL_NODISCARD
ETL_CONSTEXPR14
bool ok() const
ETL_NOEXCEPT
Return
true if the weekday_indexed is valid
ETL_NODISCARD
ETL_CONSTEXPR14
bool is_weekend() const
ETL_NOEXCEPTReturn
true if the weekday_indexed is a Saturday or Sunday.
Assignment
ETL_CONSTEXPR14
etl::chrono::weekday_indexed& operator =(const etl::chrono::weekday_indexed& rhs)
ETL_NOEXCEPTDescription
Assignment operator
Access
ETL_CONSTEXPR14
etl::chrono::weekday weekday() const
ETL_NOEXCEPTDescription
Gets the weekday.
ETL_CONSTEXPR14
unsigned index() const
ETL_NOEXCEPTDescription
Gets the index.
Non-member comparison operators
ETL_CONSTEXPR14
bool operator ==(const etl::chrono::weekday_indexed& m1,
const etl::chrono::weekday_indexed& m2)
ETL_NOEXCEPTDescription
Equality operator.
ETL_CONSTEXPR14
bool operator !=(const etl::chrono::weekday_indexed& m1,
const etl::chrono::weekday_indexed& m2)
ETL_NOEXCEPTDescription
Inequality operator.
Hash
template <>
struct hash<etl::chrono::weekday_indexed>Description
Hash function for etl::chrono::weekday_indexed.