AceTime
1.3
Date and time classes for Arduino that support timezones from the TZ Database, and a system clock that can synchronize from an NTP server or an RTC chip.
src
ace_time
ExtendedZoneProcessor.cpp
1
/*
2
* MIT License
3
* Copyright (c) 2019 Brian T. Park
4
*/
5
6
#include <Print.h>
7
#include "LocalDate.h"
8
#include "ExtendedZone.h"
9
#include "ExtendedZoneProcessor.h"
10
11
namespace
ace_time {
12
13
const
extended::ZoneEra ExtendedZoneProcessor::kAnchorEra ACE_TIME_PROGMEM = {
14
nullptr
/*zonePolicy*/
,
15
nullptr
/*format*/
,
16
0
/*offsetCode*/
,
17
0
/*deltaCode*/
,
18
LocalDate::kInvalidYearTiny
/*untilYearTiny*/
,
19
1
/*untilMonth*/
,
20
1
/*untilDay*/
,
21
0
/*untilTimeCode*/
,
22
extended::ZoneContext::kSuffixW
/*untilTimeModifier*/
23
};
24
25
void
ExtendedZoneProcessor::printTo
(Print& printer)
const
{
26
printer.print(
ExtendedZone
(mZoneInfo.zoneInfo()).name());
27
}
28
29
void
ExtendedZoneProcessor::printShortTo
(Print& printer)
const
{
30
printer.print(
ExtendedZone
(mZoneInfo.zoneInfo()).shortName());
31
}
32
33
}
ace_time::ExtendedZoneProcessor::printShortTo
void printShortTo(Print &printer) const override
Print a short human-readable identifier (e.g.
Definition:
ExtendedZoneProcessor.cpp:29
ace_time::ExtendedZone
A thin wrapper around an extended::ZoneInfo data structure to provide a stable API access to some use...
Definition:
ExtendedZone.h:23
ace_time::LocalDate::kInvalidYearTiny
static const int8_t kInvalidYearTiny
Sentinel yearTiny which indicates an error condition or sometimes a year that 'does not exist'.
Definition:
LocalDate.h:45
ace_time::ExtendedZoneProcessor::printTo
void printTo(Print &printer) const override
Print a human-readable identifier (e.g.
Definition:
ExtendedZoneProcessor.cpp:25
Generated by
1.8.17