|
| static const unsigned int | min_year = 1400 |
| static const unsigned int | max_year = 9999 |
Definition at line 45 of file gnc-timezone.hpp.
◆ TimeZoneProvider()
| TimeZoneProvider::TimeZoneProvider |
( |
| ) |
|
|
inline |
Definition at line 49 of file gnc-timezone.hpp.
49: TimeZoneProvider (static_cast<std::string>("")) {}
◆ dump()
| void TimeZoneProvider::dump |
( |
| ) |
const |
|
noexcept |
Definition at line 786 of file gnc-timezone.cpp.
787{
788 for (const auto& zone : m_zone_vector)
789 std::cout << zone.first << ": " << zone.second->to_posix_string() << "\n";
790}
◆ get()
| TZ_Ptr TimeZoneProvider::get |
( |
int | year | ) |
const |
|
noexcept |
Definition at line 774 of file gnc-timezone.cpp.
775{
776 if (m_zone_vector.empty())
777 return TZ_Ptr(new PTZ("UTC0"));
778 auto iter = find_if(m_zone_vector.rbegin(), m_zone_vector.rend(),
779 [=](TZ_Entry e) { return e.first <= year; });
780 if (iter == m_zone_vector.rend())
781 return m_zone_vector.front().second;
782 return iter->second;
783}
◆ max_year
| const unsigned int TimeZoneProvider::max_year = 9999 |
|
static |
◆ min_year
| const unsigned int TimeZoneProvider::min_year = 1400 |
|
static |
The documentation for this class was generated from the following files: