QtBase  v6.3.1
qdatetime.h
Go to the documentation of this file.
1 /****************************************************************************
2 **
3 ** Copyright (C) 2021 The Qt Company Ltd.
4 ** Copyright (C) 2021 Intel Corporation.
5 ** Contact: https://www.qt.io/licensing/
6 **
7 ** This file is part of the QtCore module of the Qt Toolkit.
8 **
9 ** $QT_BEGIN_LICENSE:LGPL$
10 ** Commercial License Usage
11 ** Licensees holding valid commercial Qt licenses may use this file in
12 ** accordance with the commercial license agreement provided with the
13 ** Software or, alternatively, in accordance with the terms contained in
14 ** a written agreement between you and The Qt Company. For licensing terms
15 ** and conditions see https://www.qt.io/terms-conditions. For further
16 ** information use the contact form at https://www.qt.io/contact-us.
17 **
18 ** GNU Lesser General Public License Usage
19 ** Alternatively, this file may be used under the terms of the GNU Lesser
20 ** General Public License version 3 as published by the Free Software
21 ** Foundation and appearing in the file LICENSE.LGPL3 included in the
22 ** packaging of this file. Please review the following information to
23 ** ensure the GNU Lesser General Public License version 3 requirements
24 ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
25 **
26 ** GNU General Public License Usage
27 ** Alternatively, this file may be used under the terms of the GNU
28 ** General Public License version 2.0 or (at your option) the GNU General
29 ** Public license version 3 or any later version approved by the KDE Free
30 ** Qt Foundation. The licenses are as published by the Free Software
31 ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
32 ** included in the packaging of this file. Please review the following
33 ** information to ensure the GNU General Public License requirements will
34 ** be met: https://www.gnu.org/licenses/gpl-2.0.html and
35 ** https://www.gnu.org/licenses/gpl-3.0.html.
36 **
37 ** $QT_END_LICENSE$
38 **
39 ****************************************************************************/
40 
41 #ifndef QDATETIME_H
42 #define QDATETIME_H
43 
44 #include <QtCore/qstring.h>
45 #include <QtCore/qnamespace.h>
46 #include <QtCore/qshareddata.h>
47 #include <QtCore/qcalendar.h>
48 
49 #include <limits>
50 
51 #if defined(Q_OS_DARWIN) || defined(Q_QDOC)
54 #endif
55 
57 
58 #if QT_CONFIG(timezone)
59 class QTimeZone;
60 #endif
61 class QDateTime;
62 
63 class Q_CORE_EXPORT QDate
64 {
65  explicit constexpr QDate(qint64 julianDay) : jd(julianDay) {}
66 public:
67  constexpr QDate() : jd(nullJd()) {}
68  QDate(int y, int m, int d);
69  QDate(int y, int m, int d, QCalendar cal);
70 
71  constexpr bool isNull() const { return !isValid(); }
72  constexpr bool isValid() const { return jd >= minJd() && jd <= maxJd(); }
73 
74  // Gregorian-optimized:
75  int year() const;
76  int month() const;
77  int day() const;
78  int dayOfWeek() const;
79  int dayOfYear() const;
80  int daysInMonth() const;
81  int daysInYear() const;
82  int weekNumber(int *yearNum = nullptr) const; // ISO 8601, always Gregorian
83 
84  int year(QCalendar cal) const;
85  int month(QCalendar cal) const;
86  int day(QCalendar cal) const;
87  int dayOfWeek(QCalendar cal) const;
88  int dayOfYear(QCalendar cal) const;
89  int daysInMonth(QCalendar cal) const;
90  int daysInYear(QCalendar cal) const;
91 
92  QDateTime startOfDay(Qt::TimeSpec spec = Qt::LocalTime, int offsetSeconds = 0) const;
93  QDateTime endOfDay(Qt::TimeSpec spec = Qt::LocalTime, int offsetSeconds = 0) const;
94 #if QT_CONFIG(timezone)
95  QDateTime startOfDay(const QTimeZone &zone) const;
96  QDateTime endOfDay(const QTimeZone &zone) const;
97 #endif
98 
99 #if QT_CONFIG(datestring)
100  QString toString(Qt::DateFormat format = Qt::TextDate) const;
101 # if QT_STRINGVIEW_LEVEL < 2
102  QString toString(const QString &format, QCalendar cal = QCalendar()) const
103  { return toString(qToStringViewIgnoringNull(format), cal); }
104 # endif
106 #endif
107  bool setDate(int year, int month, int day); // Gregorian-optimized
108  bool setDate(int year, int month, int day, QCalendar cal);
109 
110  void getDate(int *year, int *month, int *day) const;
111 
112  [[nodiscard]] QDate addDays(qint64 days) const;
113  // Gregorian-optimized:
114  [[nodiscard]] QDate addMonths(int months) const;
115  [[nodiscard]] QDate addYears(int years) const;
116  [[nodiscard]] QDate addMonths(int months, QCalendar cal) const;
117  [[nodiscard]] QDate addYears(int years, QCalendar cal) const;
118  qint64 daysTo(QDate d) const;
119 
120  static QDate currentDate();
121 #if QT_CONFIG(datestring)
122  static QDate fromString(QStringView string, Qt::DateFormat format = Qt::TextDate);
123  static QDate fromString(QStringView string, QStringView format, QCalendar cal = QCalendar())
124  { return fromString(string.toString(), format, cal); }
125  static QDate fromString(const QString &string, QStringView format, QCalendar cal = QCalendar());
126 # if QT_STRINGVIEW_LEVEL < 2
127  static QDate fromString(const QString &string, Qt::DateFormat format = Qt::TextDate)
128  { return fromString(qToStringViewIgnoringNull(string), format); }
129  static QDate fromString(const QString &string, const QString &format,
130  QCalendar cal = QCalendar())
131  { return fromString(string, qToStringViewIgnoringNull(format), cal); }
132 # endif
133 #endif
134  static bool isValid(int y, int m, int d);
135  static bool isLeapYear(int year);
136 
137  static constexpr inline QDate fromJulianDay(qint64 jd_)
138  { return jd_ >= minJd() && jd_ <= maxJd() ? QDate(jd_) : QDate() ; }
139  constexpr inline qint64 toJulianDay() const { return jd; }
140 
141 private:
142  // using extra parentheses around min to avoid expanding it if it is a macro
143  static constexpr inline qint64 nullJd() { return (std::numeric_limits<qint64>::min)(); }
144  static constexpr inline qint64 minJd() { return Q_INT64_C(-784350574879); }
145  static constexpr inline qint64 maxJd() { return Q_INT64_C( 784354017364); }
146 
147  qint64 jd;
148 
149  friend class QDateTime;
150  friend class QDateTimePrivate;
151 
152  friend constexpr bool operator==(QDate lhs, QDate rhs) { return lhs.jd == rhs.jd; }
153  friend constexpr bool operator!=(QDate lhs, QDate rhs) { return lhs.jd != rhs.jd; }
154  friend constexpr bool operator< (QDate lhs, QDate rhs) { return lhs.jd < rhs.jd; }
155  friend constexpr bool operator<=(QDate lhs, QDate rhs) { return lhs.jd <= rhs.jd; }
156  friend constexpr bool operator> (QDate lhs, QDate rhs) { return lhs.jd > rhs.jd; }
157  friend constexpr bool operator>=(QDate lhs, QDate rhs) { return lhs.jd >= rhs.jd; }
158 #ifndef QT_NO_DATASTREAM
159  friend Q_CORE_EXPORT QDataStream &operator<<(QDataStream &, QDate);
160  friend Q_CORE_EXPORT QDataStream &operator>>(QDataStream &, QDate &);
161 #endif
162 };
164 
165 class Q_CORE_EXPORT QTime
166 {
167  explicit constexpr QTime(int ms) : mds(ms)
168  {}
169 public:
170  constexpr QTime(): mds(NullTime)
171  {}
172  QTime(int h, int m, int s = 0, int ms = 0);
173 
174  constexpr bool isNull() const { return mds == NullTime; }
175  bool isValid() const;
176 
177  int hour() const;
178  int minute() const;
179  int second() const;
180  int msec() const;
181 #if QT_CONFIG(datestring)
182  QString toString(Qt::DateFormat f = Qt::TextDate) const;
183 #if QT_STRINGVIEW_LEVEL < 2
184  QString toString(const QString &format) const
185  { return toString(qToStringViewIgnoringNull(format)); }
186 #endif
188 #endif
189  bool setHMS(int h, int m, int s, int ms = 0);
190 
191  [[nodiscard]] QTime addSecs(int secs) const;
192  int secsTo(QTime t) const;
193  [[nodiscard]] QTime addMSecs(int ms) const;
194  int msecsTo(QTime t) const;
195 
196  static constexpr inline QTime fromMSecsSinceStartOfDay(int msecs) { return QTime(msecs); }
197  constexpr inline int msecsSinceStartOfDay() const { return mds == NullTime ? 0 : mds; }
198 
199  static QTime currentTime();
200 #if QT_CONFIG(datestring)
201  static QTime fromString(QStringView string, Qt::DateFormat format = Qt::TextDate);
202  static QTime fromString(QStringView string, QStringView format)
203  { return fromString(string.toString(), format); }
204  static QTime fromString(const QString &string, QStringView format);
205 # if QT_STRINGVIEW_LEVEL < 2
206  static QTime fromString(const QString &string, Qt::DateFormat format = Qt::TextDate)
207  { return fromString(qToStringViewIgnoringNull(string), format); }
208  static QTime fromString(const QString &string, const QString &format)
209  { return fromString(string, qToStringViewIgnoringNull(format)); }
210 # endif
211 #endif
212  static bool isValid(int h, int m, int s, int ms = 0);
213 
214 private:
215  enum TimeFlag { NullTime = -1 };
216  constexpr inline int ds() const { return mds == -1 ? 0 : mds; }
217  int mds;
218 
219  friend constexpr bool operator==(QTime lhs, QTime rhs) { return lhs.mds == rhs.mds; }
220  friend constexpr bool operator!=(QTime lhs, QTime rhs) { return lhs.mds != rhs.mds; }
221  friend constexpr bool operator< (QTime lhs, QTime rhs) { return lhs.mds < rhs.mds; }
222  friend constexpr bool operator<=(QTime lhs, QTime rhs) { return lhs.mds <= rhs.mds; }
223  friend constexpr bool operator> (QTime lhs, QTime rhs) { return lhs.mds > rhs.mds; }
224  friend constexpr bool operator>=(QTime lhs, QTime rhs) { return lhs.mds >= rhs.mds; }
225 
226  friend class QDateTime;
227  friend class QDateTimePrivate;
228 #ifndef QT_NO_DATASTREAM
229  friend Q_CORE_EXPORT QDataStream &operator<<(QDataStream &, QTime);
230  friend Q_CORE_EXPORT QDataStream &operator>>(QDataStream &, QTime &);
231 #endif
232 };
234 
235 class QDateTimePrivate;
236 
237 class Q_CORE_EXPORT QDateTime
238 {
239  struct ShortData {
240 #if Q_BYTE_ORDER == Q_LITTLE_ENDIAN
241  quintptr status : 8;
242 #endif
243 #if QT_VERSION >= QT_VERSION_CHECK(7,0,0)
244  qint64 msecs : 56;
245 #else
246  // note: this is only 24 bits on 32-bit systems...
247  qintptr msecs : sizeof(void *) * 8 - 8;
248 #endif
249 
250 #if Q_BYTE_ORDER == Q_BIG_ENDIAN
251  quintptr status : 8;
252 #endif
253  };
254 
255  union Data {
256  enum {
257  // To be of any use, we need at least 60 years around 1970, which
258  // is 1,893,456,000,000 ms. That requires 41 bits to store, plus
259  // the sign bit. With the status byte, the minimum size is 50 bits.
260  CanBeSmall = sizeof(ShortData) * 8 > 50
261  };
262 
263  Data() noexcept;
265  Data(const Data &other);
266  Data(Data &&other);
267  Data &operator=(const Data &other);
268  ~Data();
269 
270  void swap(Data &other) noexcept
271  { std::swap(data, other.data); }
272 
273  bool isShort() const;
274  void detach();
275 
276  const QDateTimePrivate *operator->() const;
277  QDateTimePrivate *operator->();
278 
280  ShortData data;
281  };
282 
283 public:
284  QDateTime() noexcept;
285  QDateTime(QDate date, QTime time, Qt::TimeSpec spec = Qt::LocalTime, int offsetSeconds = 0);
286 #if QT_CONFIG(timezone)
287  QDateTime(QDate date, QTime time, const QTimeZone &timeZone);
288 #endif // timezone
289  QDateTime(const QDateTime &other) noexcept;
290  QDateTime(QDateTime &&other) noexcept;
291  ~QDateTime();
292 
294  QDateTime &operator=(const QDateTime &other) noexcept;
295 
296  void swap(QDateTime &other) noexcept { d.swap(other.d); }
297 
298  bool isNull() const;
299  bool isValid() const;
300 
301  QDate date() const;
302  QTime time() const;
303  Qt::TimeSpec timeSpec() const;
304  int offsetFromUtc() const;
305 #if QT_CONFIG(timezone)
306  QTimeZone timeZone() const;
307 #endif // timezone
308  QString timeZoneAbbreviation() const;
309  bool isDaylightTime() const;
310 
311  qint64 toMSecsSinceEpoch() const;
312  qint64 toSecsSinceEpoch() const;
313 
314  void setDate(QDate date);
315  void setTime(QTime time);
316  void setTimeSpec(Qt::TimeSpec spec);
317  void setOffsetFromUtc(int offsetSeconds);
318 #if QT_CONFIG(timezone)
319  void setTimeZone(const QTimeZone &toZone);
320 #endif // timezone
321  void setMSecsSinceEpoch(qint64 msecs);
322  void setSecsSinceEpoch(qint64 secs);
323 
324 #if QT_CONFIG(datestring)
325  QString toString(Qt::DateFormat format = Qt::TextDate) const;
326 # if QT_STRINGVIEW_LEVEL < 2
327  QString toString(const QString &format, QCalendar cal = QCalendar()) const
328  { return toString(qToStringViewIgnoringNull(format), cal); }
329 # endif
331 #endif
332  [[nodiscard]] QDateTime addDays(qint64 days) const;
333  [[nodiscard]] QDateTime addMonths(int months) const;
334  [[nodiscard]] QDateTime addYears(int years) const;
335  [[nodiscard]] QDateTime addSecs(qint64 secs) const;
336  [[nodiscard]] QDateTime addMSecs(qint64 msecs) const;
337 
338  QDateTime toTimeSpec(Qt::TimeSpec spec) const;
339  inline QDateTime toLocalTime() const { return toTimeSpec(Qt::LocalTime); }
340  inline QDateTime toUTC() const { return toTimeSpec(Qt::UTC); }
341  QDateTime toOffsetFromUtc(int offsetSeconds) const;
342 #if QT_CONFIG(timezone)
343  QDateTime toTimeZone(const QTimeZone &toZone) const;
344 #endif // timezone
345 
346  qint64 daysTo(const QDateTime &) const;
347  qint64 secsTo(const QDateTime &) const;
348  qint64 msecsTo(const QDateTime &) const;
349 
352 #if QT_CONFIG(datestring)
353  static QDateTime fromString(QStringView string, Qt::DateFormat format = Qt::TextDate);
354  static QDateTime fromString(QStringView string, QStringView format,
355  QCalendar cal = QCalendar())
356  { return fromString(string.toString(), format, cal); }
357  static QDateTime fromString(const QString &string, QStringView format,
358  QCalendar cal = QCalendar());
359 # if QT_STRINGVIEW_LEVEL < 2
360  static QDateTime fromString(const QString &string, Qt::DateFormat format = Qt::TextDate)
361  { return fromString(qToStringViewIgnoringNull(string), format); }
362  static QDateTime fromString(const QString &string, const QString &format,
363  QCalendar cal = QCalendar())
364  { return fromString(string, qToStringViewIgnoringNull(format), cal); }
365 # endif
366 #endif
367 
368  static QDateTime fromMSecsSinceEpoch(qint64 msecs, Qt::TimeSpec spec = Qt::LocalTime,
369  int offsetFromUtc = 0);
370  static QDateTime fromSecsSinceEpoch(qint64 secs, Qt::TimeSpec spec = Qt::LocalTime,
371  int offsetFromUtc = 0);
372 
373 #if QT_CONFIG(timezone)
374  static QDateTime fromMSecsSinceEpoch(qint64 msecs, const QTimeZone &timeZone);
375  static QDateTime fromSecsSinceEpoch(qint64 secs, const QTimeZone &timeZone);
376 #endif
377 
378  static qint64 currentMSecsSinceEpoch() noexcept;
379  static qint64 currentSecsSinceEpoch() noexcept;
380 
381 #if defined(Q_OS_DARWIN) || defined(Q_QDOC)
382  static QDateTime fromCFDate(CFDateRef date);
383  CFDateRef toCFDate() const Q_DECL_CF_RETURNS_RETAINED;
384  static QDateTime fromNSDate(const NSDate *date);
385  NSDate *toNSDate() const Q_DECL_NS_RETURNS_AUTORELEASED;
386 #endif
387 
388  // (1<<63) ms is 292277024.6 (average Gregorian) years, counted from the start of 1970, so
389  // Last is floor(1970 + 292277024.6); no year 0, so First is floor(1970 - 1 - 292277024.6)
390  enum class YearRange : qint32 { First = -292275056, Last = +292278994 };
391 
392 private:
393  bool equals(const QDateTime &other) const;
394  bool precedes(const QDateTime &other) const;
395  friend class QDateTimePrivate;
396 
397  Data d;
398 
399  friend bool operator==(const QDateTime &lhs, const QDateTime &rhs) { return lhs.equals(rhs); }
400  friend bool operator!=(const QDateTime &lhs, const QDateTime &rhs) { return !(lhs == rhs); }
401  friend bool operator<(const QDateTime &lhs, const QDateTime &rhs) { return lhs.precedes(rhs); }
402  friend bool operator<=(const QDateTime &lhs, const QDateTime &rhs) { return !(rhs < lhs); }
403  friend bool operator>(const QDateTime &lhs, const QDateTime &rhs) { return rhs.precedes(lhs); }
404  friend bool operator>=(const QDateTime &lhs, const QDateTime &rhs) { return !(lhs < rhs); }
405 
406 #ifndef QT_NO_DATASTREAM
407  friend Q_CORE_EXPORT QDataStream &operator<<(QDataStream &, const QDateTime &);
408  friend Q_CORE_EXPORT QDataStream &operator>>(QDataStream &, QDateTime &);
409 #endif
410 
411 #if !defined(QT_NO_DEBUG_STREAM) && QT_CONFIG(datestring)
412  friend Q_CORE_EXPORT QDebug operator<<(QDebug, const QDateTime &);
413 #endif
414 };
416 
417 #ifndef QT_NO_DATASTREAM
422 Q_CORE_EXPORT QDataStream &operator<<(QDataStream &, const QDateTime &);
424 #endif // QT_NO_DATASTREAM
425 
426 #if !defined(QT_NO_DEBUG_STREAM) && QT_CONFIG(datestring)
427 Q_CORE_EXPORT QDebug operator<<(QDebug, QDate);
428 Q_CORE_EXPORT QDebug operator<<(QDebug, QTime);
429 Q_CORE_EXPORT QDebug operator<<(QDebug, const QDateTime &);
430 #endif
431 
432 // QDateTime is not noexcept for now -- to be revised once
433 // timezone and calendaring support is added
434 Q_CORE_EXPORT size_t qHash(const QDateTime &key, size_t seed = 0);
435 Q_CORE_EXPORT size_t qHash(QDate key, size_t seed = 0) noexcept;
436 Q_CORE_EXPORT size_t qHash(QTime key, size_t seed = 0) noexcept;
437 
439 
440 #endif // QDATETIME_H
The QCalendar class describes calendar systems.
Definition: qcalendar.h:89
The QDataStream class provides serialization of binary data to a QIODevice.
Definition: qdatastream.h:66
operator>>(QDataStream &ds, qfloat16 &f)
Definition: qfloat16.cpp:344
operator<<(QDataStream &ds, qfloat16 f)
Definition: qfloat16.cpp:327
The QDate class provides date functions.
Definition: qdatetime.h:64
constexpr bool isValid() const
Definition: qdatetime.h:72
constexpr qint64 toJulianDay() const
Definition: qdatetime.h:139
static constexpr QDate fromJulianDay(qint64 jd_)
Definition: qdatetime.h:137
constexpr bool isNull() const
Definition: qdatetime.h:71
constexpr friend bool operator!=(QDate lhs, QDate rhs)
Definition: qdatetime.h:153
constexpr friend bool operator>=(QDate lhs, QDate rhs)
Definition: qdatetime.h:157
static QDate currentDate()
constexpr QDate()
Definition: qdatetime.h:67
constexpr friend bool operator<=(QDate lhs, QDate rhs)
Definition: qdatetime.h:155
constexpr friend bool operator==(QDate lhs, QDate rhs)
Definition: qdatetime.h:152
The QDateTime class provides date and time functions.
Definition: qdatetime.h:238
static QDateTime currentDateTime()
friend bool operator>(const QDateTime &lhs, const QDateTime &rhs)
Definition: qdatetime.h:403
friend bool operator<=(const QDateTime &lhs, const QDateTime &rhs)
Definition: qdatetime.h:402
friend bool operator!=(const QDateTime &lhs, const QDateTime &rhs)
Definition: qdatetime.h:400
friend bool operator>=(const QDateTime &lhs, const QDateTime &rhs)
Definition: qdatetime.h:404
QDateTime toUTC() const
Definition: qdatetime.h:340
QDateTime toLocalTime() const
Definition: qdatetime.h:339
friend bool operator==(const QDateTime &lhs, const QDateTime &rhs)
Definition: qdatetime.h:399
static QDateTime currentDateTimeUtc()
static qint64 currentMSecsSinceEpoch() noexcept
friend bool operator<(const QDateTime &lhs, const QDateTime &rhs)
Definition: qdatetime.h:401
void swap(QDateTime &other) noexcept
Definition: qdatetime.h:296
The QDebug class provides an output stream for debugging information.
Definition: qdebug.h:65
template< typename Enum > size_t qHash(QFlags< Enum > flags, size_t seed=0) noexcept
The QString class provides a Unicode character string.
Definition: qstring.h:388
The QStringView class provides a unified view on UTF-16 strings with a read-only subset of the QStrin...
Definition: qstringview.h:122
The QTime class provides clock time functions.
Definition: qdatetime.h:166
constexpr friend bool operator<=(QTime lhs, QTime rhs)
Definition: qdatetime.h:222
constexpr bool isNull() const
Definition: qdatetime.h:174
static QTime currentTime()
constexpr friend bool operator==(QTime lhs, QTime rhs)
Definition: qdatetime.h:219
constexpr friend bool operator!=(QTime lhs, QTime rhs)
Definition: qdatetime.h:220
static constexpr QTime fromMSecsSinceStartOfDay(int msecs)
Definition: qdatetime.h:196
constexpr int msecsSinceStartOfDay() const
Definition: qdatetime.h:197
constexpr friend bool operator>=(QTime lhs, QTime rhs)
Definition: qdatetime.h:224
constexpr QTime()
Definition: qdatetime.h:170
The QTimeZone class converts between UTC and local time in a specific time zone.
Definition: qtimezone.h:60
QDate date
[1]
auto it unsigned count const
Definition: hb-iter.hh:848
QT_BEGIN_NAMESPACE bool operator<(const QMimeType &t1, const QMimeType &t2)
void toString(QString &appendTo, IPv4Address address)
Definition: qipaddress.cpp:131
std::chrono::milliseconds ms
TimeSpec
Definition: qnamespace.h:1259
@ UTC
Definition: qnamespace.h:1261
@ LocalTime
Definition: qnamespace.h:1260
DateFormat
Definition: qnamespace.h:1252
@ TextDate
Definition: qnamespace.h:1253
void swap(SimpleVector< T > &v1, SimpleVector< T > &v2)
Definition: simplevector.h:331
#define Q_DECL_NS_RETURNS_AUTORELEASED
#define Q_DECL_CF_RETURNS_RETAINED
Q_FORWARD_DECLARE_OBJC_CLASS(NSObject)
Q_FORWARD_DECLARE_CF_TYPE(CTFontDescriptor)
QDateTimePrivate::QDateTimeShortData ShortData
Definition: qdatetime.cpp:2372
Q_DECLARE_TYPEINFO(QDate, Q_RELOCATABLE_TYPE)
Q_CORE_EXPORT QDataStream & operator>>(QDataStream &, QDate &)
Q_CORE_EXPORT QDataStream & operator<<(QDataStream &, QDate)
constexpr bool operator>(const QFixed &f, int i)
Definition: qfixed_p.h:182
size_t quintptr
Definition: qglobal.h:310
int qint32
Definition: qglobal.h:287
long long qint64
Definition: qglobal.h:298
#define QT_MOVE_ASSIGNMENT_OPERATOR_IMPL_VIA_PURE_SWAP(Class)
Definition: qglobal.h:563
#define Q_INT64_C(c)
Definition: qglobal.h:295
ptrdiff_t qintptr
Definition: qglobal.h:309
const GLfloat * m
GLuint64 key
GLfloat GLfloat f
GLint GLsizei GLsizei GLenum GLenum GLsizei void * data
GLint GLsizei GLsizei GLenum format
GLint y
GLfloat GLfloat GLfloat GLfloat h
GLdouble GLdouble t
[9]
Definition: qopenglext.h:243
GLdouble s
[6]
Definition: qopenglext.h:235
@ Data
QStringView qToStringViewIgnoringNull(const QStringLike &s) noexcept
Definition: qstringview.h:480
#define Q_DECLARE_SHARED(TYPE)
Definition: qtypeinfo.h:197
@ Q_RELOCATABLE_TYPE
Definition: qtypeinfo.h:156
d1 daysTo(d2)
QTime time
[5]
QSharedPointer< T > other(t)
[5]
this swap(other)
#define rhs