6 #ifndef ACE_TIME_COMMON_DATE_STRINGS_H 7 #define ACE_TIME_COMMON_DATE_STRINGS_H 39 uint8_t index = (month < kNumMonthNames) ? month : 0;
40 strcpy_P(mBuffer, kMonthNames[index]);
46 uint8_t index = (month < kNumMonthNames) ? month : 0;
47 strncpy_P(mBuffer, kMonthNames[index], kShortNameLength);
54 uint8_t index = (dayOfWeek < kNumDayOfWeekNames) ? dayOfWeek : 0;
55 strcpy_P(mBuffer, kDayOfWeekNames[index]);
61 uint8_t index = (dayOfWeek < kNumDayOfWeekNames) ? dayOfWeek : 0;
62 strncpy_P(mBuffer, kDayOfWeekNames[index], kShortNameLength);
68 static const char *
const kDayOfWeekNames[];
69 static const char *
const kMonthNames[];
70 static const uint8_t kNumDayOfWeekNames;
71 static const uint8_t kNumMonthNames;
Class that translates a numeric month (1-12) or dayOfWeek (1-7) into a human readable string...
static const uint8_t kShortNameLength
Number of prefix characters to use to create a short name.
const char * monthLongString(uint8_t month)
Return the long month name.
const char * monthShortString(uint8_t month)
Return the short month name.
static const uint8_t kBufferSize
Length of the longest month or week name, including the '\0' terminator.
const char * dayOfWeekLongString(uint8_t dayOfWeek)
Return the short dayOfWeek name.
const char * dayOfWeekShortString(uint8_t dayOfWeek)
Return the short dayOfWeek name.