10 using ace_common::printPad2To;
16 printer.print(F(
"<Invalid LocalTime>"));
21 printPad2To(printer, mHour,
'0');
23 printPad2To(printer, mMinute,
'0');
25 printPad2To(printer, mSecond,
'0');
29 if (strlen(timeString) < kTimeStringLength) {
37 const char* s = timeString;
40 uint8_t
hour = (*s++ -
'0');
47 uint8_t
minute = (*s++ -
'0');
54 uint8_t
second = (*s++ -
'0');
The time (hour, minute, second) fields representing the time without regards to the day or the time z...
static LocalTime forTimeStringChainable(const char *&timeString)
Variant of forTimeString() that updates the pointer to the next unprocessed character.
static LocalTime forError()
Factory method that returns an instance which indicates an error condition.
static LocalTime forTimeString(const char *timeString)
Factory method.
void printTo(Print &printer) const
Print LocalTime to 'printer' in ISO 8601 format.
LocalTime()
Default constructor does nothing.
uint8_t hour() const
Return the hour.
uint8_t minute() const
Return the minute.
uint8_t second() const
Return the second.
bool isError() const
Return true if any component is outside the normal time range of 00:00:00 to 23:59:59.