wxDateTime_t minute = 0, wxDateTime_t second = 0,
wxDateTime_t millisec = 0);
+ /**
+ Same as SetFromMSWSysTime.
+
+ @param st
+ Input, Windows SYSTEMTIME reference
+ @since 2.9.0
+ @remarks MSW only
+ */
+ wxDateTime(const struct _SYSTEMTIME& st);
+
+
/**
Reset time to midnight (00:00:00) without changing the date.
*/
*/
long unsigned int GetAsDOS() const;
+ /**
+ Initialize using the Windows SYSTEMTIME structure.
+ @param st
+ Input, Windows SYSTEMTIME reference
+ @since 2.9.0
+ @remarks MSW only
+ */
+ wxDateTime& SetFromMSWSysTime(const struct _SYSTEMTIME& st);
+
+ /**
+ Returns the date and time in the Windows SYSTEMTIME format.
+ @param st
+ Output, pointer to Windows SYSTEMTIME
+ @since 2.9.0
+ @remarks MSW only
+ */
+ void GetAsMSWSysTime(struct _SYSTEMTIME* st) const;
+
/**
Returns the century of this date.
*/
be specified. It is thus less flexible then ParseDateTime(), but also
has less chances to misinterpret the user input.
- @returns @NULL if the conversion failed, otherwise return the pointer
+ @return @NULL if the conversion failed, otherwise return the pointer
to the character which stopped the scan.
*/
const char* ParseDate(const wxString& date,
be specified. It is thus less flexible then ParseDateTime(), but also
has less chances to misinterpret the user input.
- @returns @NULL if the conversion failed, otherwise return the pointer
+ @return @NULL if the conversion failed, otherwise return the pointer
to the character which stopped the scan.
*/
const char* ParseDate(const char* date);
be specified. It is thus less flexible then ParseDateTime(), but also
has less chances to misinterpret the user input.
- @returns @NULL if the conversion failed, otherwise return the pointer
+ @return @NULL if the conversion failed, otherwise return the pointer
to the character which stopped the scan.
*/
const wchar_t* ParseDate(const wchar_t* date);
anything that may be accepted and will only reject strings which can
not be parsed in any way at all.
- @returns @NULL if the conversion failed, otherwise return the pointer
+ @return @NULL if the conversion failed, otherwise return the pointer
to the character which stopped the scan.
*/
const char* ParseDateTime(const wxString& datetime,
anything that may be accepted and will only reject strings which can
not be parsed in any way at all.
- @returns @NULL if the conversion failed, otherwise return the pointer
+ @return @NULL if the conversion failed, otherwise return the pointer
to the character which stopped the scan.
*/
const char* ParseDateTime(const char* datetime);
anything that may be accepted and will only reject strings which can
not be parsed in any way at all.
- @returns @NULL if the conversion failed, otherwise return the pointer
+ @return @NULL if the conversion failed, otherwise return the pointer
to the character which stopped the scan.
*/
const wchar_t* ParseDateTime(const wchar_t* datetime);
@a dateDef. If it is not specified, Today() is used as the default
date.
- @returns @NULL if the conversion failed, otherwise return the pointer
+ @return @NULL if the conversion failed, otherwise return the pointer
to the character which stopped the scan.
*/
const char* ParseFormat(const wxString& date,
@a dateDef. If it is not specified, Today() is used as the default
date.
- @returns @NULL if the conversion failed, otherwise return the pointer
+ @return @NULL if the conversion failed, otherwise return the pointer
to the character which stopped the scan.
*/
const char* ParseFormat(const char* date,
@a dateDef. If it is not specified, Today() is used as the default
date.
- @returns @NULL if the conversion failed, otherwise return the pointer
+ @return @NULL if the conversion failed, otherwise return the pointer
to the character which stopped the scan.
*/
const wchar_t* ParseFormat(const wchar_t* date,
the date and time parts must be equal to @a sep for the function to
succeed.
- @returns @true if the entire string was parsed successfully, @false
+ @return @true if the entire string was parsed successfully, @false
otherwise.
*/
bool ParseISOCombined(const wxString& date, char sep = 'T');
/**
This function parses the date in ISO 8601 format @c "YYYY-MM-DD".
- @returns @true if the entire string was parsed successfully, @false
+ @return @true if the entire string was parsed successfully, @false
otherwise.
*/
bool ParseISODate(const wxString& date);
/**
This function parses the time in ISO 8601 format @c "HH:MM:SS".
- @returns @true if the entire string was parsed successfully, @false
+ @return @true if the entire string was parsed successfully, @false
otherwise.
*/
bool ParseISOTime(const wxString& date);
This functions is like ParseDateTime(), but only allows the time to be
specified in the input string.
- @returns @NULL if the conversion failed, otherwise return the pointer
+ @return @NULL if the conversion failed, otherwise return the pointer
to the character which stopped the scan.
*/
const char* ParseTime(const wxString& time,
This functions is like ParseDateTime(), but only allows the time to be
specified in the input string.
- @returns @NULL if the conversion failed, otherwise return the pointer
+ @return @NULL if the conversion failed, otherwise return the pointer
to the character which stopped the scan.
*/
const char* ParseTime(const char* time);
This functions is like ParseDateTime(), but only allows the time to be
specified in the input string.
- @returns @NULL if the conversion failed, otherwise return the pointer
+ @return @NULL if the conversion failed, otherwise return the pointer
to the character which stopped the scan.
*/
const wchar_t* ParseTime(const wchar_t* time);
Sets the date to the last day in the specified month (the current one
by default).
- @returns The reference to the modified object itself.
+ @return The reference to the modified object itself.
*/
wxDateTime SetToLastMonthDay(Month month = Inv_Month,
int year = Inv_Year);
Sets the date so that it will be the first @a weekday following the
current date.
- @returns The reference to the modified object itself.
+ @return The reference to the modified object itself.
*/
wxDateTime& SetToNextWeekDay(WeekDay weekday);
Sets the date so that it will be the last @a weekday before the current
date.
- @returns The reference to the modified object itself.
+ @return The reference to the modified object itself.
*/
wxDateTime& SetToPrevWeekDay(WeekDay weekday);
SetToWeekDay(-1, wxDateTime::Sun) will set the date to the last Sunday
in the current month.
- @returns @true if the date was modified successfully, @false otherwise
+ @return @true if the date was modified successfully, @false otherwise
meaning that the specified date doesn't exist.
*/
bool SetToWeekDay(WeekDay weekday, int n = 1,
Adjusts the date so that it will still lie in the same week as before,
but its week day will be the given one.
- @returns The reference to the modified object itself.
+ @return The reference to the modified object itself.
*/
wxDateTime SetToWeekDayInSameWeek(WeekDay weekday,
WeekFlags flags = Monday_First);
number should be in the range 1-366 for the leap years and 1-365 for
the other ones.
- @returns The reference to the modified object itself.
+ @return The reference to the modified object itself.
*/
wxDateTime& SetToYearDay(wxDateTime_t yday);
Transform the date from the given time zone to the local one. If
@a noDST is @true, no DST adjustments will be made.
- @returns The date in the local time zone.
+ @return The date in the local time zone.
*/
wxDateTime FromTimezone(const TimeZone& tz, bool noDST = false) const;
Transform the date to the given time zone. If @a noDST is @true, no DST
adjustments will be made.
- @returns The date in the new time zone.
+ @return The date in the new time zone.
*/
wxDateTime ToTimezone(const TimeZone& tz, bool noDST = false) const;
/**
Returns the sum of two date spans.
- @returns A new wxDateSpan object with the result.
+ @return A new wxDateSpan object with the result.
*/
wxDateSpan Add(const wxDateSpan& other) const;
/**
product is computed by multiplying each of the components by the
@a factor.
- @returns A new wxDateSpan object with the result.
+ @return A new wxDateSpan object with the result.
*/
wxDateSpan Multiply(int factor) const;
/**
Multiplies this date span by the specified @a factor. The product is
computed by multiplying each of the components by the @a factor.
- @returns A reference to this wxDateSpan object modified in place.
+ @return A reference to this wxDateSpan object modified in place.
*/
wxDateSpan& Multiply(int factor);
/**
Returns the difference of two date spans.
- @returns A new wxDateSpan object with the result.
+ @return A new wxDateSpan object with the result.
*/
wxDateSpan Subtract(const wxDateSpan& other) const;
/**
Multiplies this date span by the specified @a factor. The product is
computed by multiplying each of the components by the @a factor.
- @returns A reference to this wxDateSpan object modified in place.
+ @return A reference to this wxDateSpan object modified in place.
*/
wxDateSpan& operator*=(int factor);
/**
Returns the sum of two time spans.
- @returns A new wxDateSpan object with the result.
+ @return A new wxDateSpan object with the result.
*/
wxTimeSpan Add(const wxTimeSpan& diff) const;
/**
/**
Returns the product of this time span by @a n.
- @returns A new wxTimeSpan object with the result.
+ @return A new wxTimeSpan object with the result.
*/
wxTimeSpan Multiply(int n) const;
/**
Multiplies this time span by @a n.
- @returns A reference to this wxTimeSpan object modified in place.
+ @return A reference to this wxTimeSpan object modified in place.
*/
wxTimeSpan& Multiply(int n);
/**
Returns the difference of two time spans.
- @returns A new wxDateSpan object with the result.
+ @return A new wxDateSpan object with the result.
*/
wxTimeSpan Subtract(const wxTimeSpan& diff) const;
/**
/**
Multiplies this time span by @a n.
- @returns A reference to this wxTimeSpan object modified in place.
+ @return A reference to this wxTimeSpan object modified in place.
*/
wxTimeSpan& operator*=(int n);