A date (dd/mm/yyyy) class.
More...
#include <gdate.h>
|
enum | Weekday {
sunday,
monday,
tuesday,
wednesday,
thursday,
friday,
saturday
} |
|
enum | Month {
january = 1,
february,
march,
april,
may,
june,
july,
august,
september,
october,
november,
december
} |
|
enum | Format { yyyy_mm_dd_slash,
yyyy_mm_dd,
mm_dd
} |
|
|
| Date () |
| Default constructor for the current date in the UTC timezone. More...
|
|
| Date (const LocalTime &) |
| Constructor for the current date in the local timezone. More...
|
|
| Date (const G::DateTime::BrokenDownTime &tm) |
| Constructor for the specified date.
|
|
| Date (G::EpochTime t) |
| Constructor for the date in the UTC timezone as at the given epoch time. More...
|
|
| Date (G::EpochTime t, const LocalTime &) |
| Constructor for the date in the local timezone as at the given epoch time. More...
|
|
| Date (int year, Month month, int day_of_month) |
| Constructor for the specified date.
|
|
std::string | string (Format format=yyyy_mm_dd_slash) const |
| Returns a string representation of the date.
|
|
Weekday | weekday () const |
| Returns the day of the week.
|
|
std::string | weekdayName (bool brief=false) const |
| Returns an english string representation of the day of the week. More...
|
|
int | monthday () const |
| Returns the day of the month.
|
|
std::string | dd () const |
| Returns the day of the month as a two-digit decimal string. More...
|
|
Month | month () const |
| Returns the month.
|
|
std::string | monthName (bool brief=false) const |
| Returns the month as a string (in english).
|
|
std::string | mm () const |
| Returns the month as a two-digit decimal string.
|
|
int | year () const |
| Returns the year.
|
|
std::string | yyyy () const |
| Returns the year as a four-digit decimal string. More...
|
|
Date & | operator++ () |
| Increments the date by one day.
|
|
Date & | operator-- () |
| Decrements the date by one day.
|
|
bool | operator== (const Date &rhs) const |
| Comparison operator.
|
|
bool | operator!= (const Date &rhs) const |
| Comparison operator.
|
|
|
static int | yearUpperLimit () |
| Returns the largest supported year value.
|
|
static int | yearLowerLimit () |
| Returns the smallest supported year value.
|
|
A date (dd/mm/yyyy) class.
- See Also
- G::Time, G::DateTime
Definition at line 39 of file gdate.h.
Default constructor for the current date in the UTC timezone.
Definition at line 38 of file gdate.cpp.
Constructor for the current date in the local timezone.
Definition at line 58 of file gdate.cpp.
Constructor for the date in the UTC timezone as at the given epoch time.
Definition at line 43 of file gdate.cpp.
Constructor for the date in the local timezone as at the given epoch time.
Definition at line 48 of file gdate.cpp.
std::string G::Date::dd |
( |
| ) |
const |
Returns the day of the month as a two-digit decimal string.
(Was monthdayString().)
Definition at line 116 of file gdate.cpp.
std::string G::Date::weekdayName |
( |
bool |
brief = false | ) |
const |
Returns an english string representation of the day of the week.
(Was weekdayString().)
Definition at line 153 of file gdate.cpp.
std::string G::Date::yyyy |
( |
| ) |
const |
Returns the year as a four-digit decimal string.
(Was yearString().)
Definition at line 192 of file gdate.cpp.
The documentation for this class was generated from the following files:
- /home/graeme/videotools/src/glib/gdate.h
- /home/graeme/videotools/src/glib/gdate.cpp