HMS values, but only on specific days of week or dates (with optional exceptions)
More...
|
| LocalTimeHMSRestricted () |
| Default constructor restricts to no valid dates!
|
|
| LocalTimeHMSRestricted (LocalTimeHMS hms) |
| Default Sets a hour minute second value on any date. More...
|
|
| LocalTimeHMSRestricted (LocalTimeHMS hms, LocalTimeRestrictedDate restrictedDate) |
| Default Sets a hour minute second value with date restrictions. More...
|
|
void | fromJson (JSONValue jsonObj) |
| Fills in this object from JSON data. More...
|
|
| LocalTimeHMS () |
| Default constructor. Sets time to 00:00:00.
|
|
virtual | ~LocalTimeHMS () |
| Destructor.
|
|
| LocalTimeHMS (const char *str) |
| Constructs the object from a time string. More...
|
|
| LocalTimeHMS (const LocalTimeValue &value) |
| Construct this HMS from a LocalTimeValue (which contains YMD and HMS) More...
|
|
void | clear () |
| Sets the hour, minute, and second to 0.
|
|
void | parse (const char *str) |
| Parse a "H:MM:SS" string. More...
|
|
String | toString () const |
| Turns the parsed data into a normalized string of the form: "HH:MM:SS" (24-hour clock, with leading zeroes)
|
|
int | toSeconds () const |
| Convert hour minute second into a number of seconds (simple multiplication and addition)
|
|
void | fromTimeInfo (const struct tm *pTimeInfo) |
| Sets the hour, minute, and second fields from a struct tm.
|
|
void | fromLocalTimeValue (const LocalTimeValue &value) |
| Sets the HMS from a LocalTimeValue. More...
|
|
void | toTimeInfo (struct tm *pTimeInfo) const |
| Fill in the tm_hour, tm_min, and tm_sec fields of a struct tm from the values in this object. More...
|
|
void | adjustTimeInfo (struct tm *pTimeInfo) const |
| Adjust the values in a struct tm from the values in this object. More...
|
|
void | fromJson (JSONValue jsonObj) |
| Parses a JSON value of type string in HH:MM:SS format. More...
|
|
LocalTimeHMS & | withHour (int hour) |
| Sets this object to be the specified hour, with minute and second set to 0. More...
|
|
LocalTimeHMS & | withHourMinute (int hour, int minute) |
| Sets this object to be the specified hour and minute, with second set to 0. More...
|
|
int | compareTo (const LocalTimeHMS &other) const |
| Compare two LocalTimeHMS objects. More...
|
|
bool | operator== (const LocalTimeHMS &other) const |
| Returns true if this item is equal to other. Compares hour, minute, and second. More...
|
|
bool | operator!= (const LocalTimeHMS &other) const |
| Returns true if this item is not equal to other. More...
|
|
bool | operator< (const LocalTimeHMS &other) const |
| Returns true if this item is < other. More...
|
|
bool | operator> (const LocalTimeHMS &other) const |
| Returns true if this item is > other. More...
|
|
bool | operator<= (const LocalTimeHMS &other) const |
| Returns true if this item <= other. More...
|
|
bool | operator>= (const LocalTimeHMS &other) const |
| Returns true if this item is >= other. More...
|
|
| LocalTimeRestrictedDate () |
| Create an empty restricted date object. It will return false for any date passed to isValid.
|
|
| LocalTimeRestrictedDate (uint8_t mask) |
| Create a date restricted object restricted to days of the week. More...
|
|
| LocalTimeRestrictedDate (uint8_t mask, std::initializer_list< const char * > onlyOnDates, std::initializer_list< const char * > exceptDates) |
| Construct an object with an initializer list of strings. More...
|
|
| LocalTimeRestrictedDate (uint8_t mask, std::initializer_list< LocalTimeYMD > onlyOnDates, std::initializer_list< LocalTimeYMD > exceptDates) |
| Construct an object with an initializer list of LocalTimeYMD objects. More...
|
|
LocalTimeRestrictedDate & | withOnAllDays () |
| Set the mask value to MASK_ALL. Does not change only on date or except on date lists. More...
|
|
LocalTimeRestrictedDate & | withOnlyOnDays (LocalTimeDayOfWeek value) |
| Restrict to days of the week. More...
|
|
LocalTimeRestrictedDate & | withOnlyOnDays (uint8_t mask) |
| Restrict to certain dates. More...
|
|
LocalTimeRestrictedDate & | withOnlyOnDates (std::initializer_list< const char * > dates) |
| Restrict to certain dates. More...
|
|
LocalTimeRestrictedDate & | withOnlyOnDates (std::initializer_list< LocalTimeYMD > dates) |
| Restrict to certain dates. More...
|
|
LocalTimeRestrictedDate & | withExceptDates (std::initializer_list< const char * > dates) |
| Dates that will always return false for isValid. More...
|
|
LocalTimeRestrictedDate & | withExceptDates (std::initializer_list< LocalTimeYMD > dates) |
| Dates that will always return false for isValid. More...
|
|
bool | isEmpty () const |
| Returns true if onlyOnDays mask is 0 and the onlyOnDates and exceptDates lists are empty. More...
|
|
void | clear () |
| Clear all settings.
|
|
bool | isValid (LocalTimeValue localTimeValue) const |
| Returns true if a date is in the onlyOnDays or onlyOnDates list, and not in the exceptDates list. More...
|
|
bool | isValid (LocalTimeYMD ymd) const |
| Returns true if a date is in the onlyOnDays or onlyOnDates list, and not in the exceptDates list. More...
|
|
bool | inOnlyOnDates (LocalTimeYMD ymd) const |
| Returns true of a date is in the onlyOnDates list. More...
|
|
bool | inExceptDates (LocalTimeYMD ymd) const |
| Returns true of a date is in the exceptDates list. More...
|
|
LocalTimeYMD | getExpirationDate () const |
| Get the last date (YMD) that this restricted date could be valid. More...
|
|
void | fromJson (JSONValue jsonObj) |
| Fills in this object from JSON data. More...
|
|
HMS values, but only on specific days of week or dates (with optional exceptions)