Äîêóìåíò âçÿò èç êýøà ïîèñêîâîé ìàøèíû. Àäðåñ
îðèãèíàëüíîãî äîêóìåíòà
: http://rtm-cs.sinp.msu.ru/manual/qt/qdatetime.html
Äàòà èçìåíåíèÿ: Sun Jul 12 02:58:58 1998 Äàòà èíäåêñèðîâàíèÿ: Mon Oct 1 20:16:38 2012 Êîäèðîâêà: |
The QDateTime class combines QDate and QTime into a single class. More...
#include <qdatetime.h>
QDateTime provides high precision date and time functions since it can work with Gregorian dates up to about year 8000.
Most countries that use the Gregorian calendar switched to it between 1550 and 1920.
Constructs a null datetime (i.e. null date and null time). A null datetime is invalid, since the date is invalid.
Constructs a datetime with date date and null time (00:00:00.000).
Constructs a datetime with date date and time time.
Returns the datetime plus ndays days.
See also: daysTo().
Returns the datetime plus nsecs seconds.
See also: secsTo().
[static]
Returns the current datetime.
See also: QDate::currentDate() and QTime::currentTime().
Returns the date part of this datetime.
See also: time().
Returns the number of days from this datetime to dt, which is negaitive if dt is in the past.
See also: addDays() and secsTo().
Returns TRUE if both the date and the time are null. A null date is invalid.
See also: QDate::isNull() and QTime::isNull().
Returns TRUE if both the date and the time are value.
See also: QDate::isValid() and QTime::isValid().
Returns TRUE if this datetime is different from dt, or FALSE if they are equal.
See also: operator==().
Returns TRUE if this datetime is before dt, otherwise FALSE.
Returns TRUE if this datetime is before or equal to dt, otherwise FALSE.
Returns TRUE if this datetime is equal to dt, or FALSE if they are different.
See also: operator!=().
Returns TRUE if this datetime is after dt, otherwise FALSE.
Returns TRUE if this datetime is equal to or after dt, otherwise FALSE.
Returns the number of seconds from this datetime to dt, which is negative if t is in the past.
Example:
QDateTime dt = QDateTime::currentDateTime(); QDateTime x( QDate(dt.year(),12,24), QTime(17,00) ); debug( "There are %d seconds to Christmas", dt.secsTo(x) );
See also: addSecs(), daysTo() and QTime::secsTo().
Sets the date part of this datetime.
See also: setTime().
Sets the time part of this datetime.
See also: setDate().
Sets the local date and time given the number of seconds that have passed since 00:00:00 on January 1, 1970, Coordinated Universal Time (UTC). On systems that do not support timezones this function will behave as if local time were UTC.
Returns the time part of this datetime.
See also: date().
Returns the datetime as a string.
The string format is "Sat May 20 1995 03:40:13".
Writes a datetime to the stream.
Serialization format: [QDate QTime].
Reads a datetime from the stream.
Search the documentation, FAQ, qt-interest archive and more (uses
www.troll.no):
This file is part of the Qt toolkit, copyright © 1995-98 Troll Tech, all rights reserved.
It was generated from the following files:
Copyright © 1998 Troll Tech | Trademarks | Qt version 1.40
|