QKnxDate Class
The QKnxDate class is a datapoint type for a date. More...
Header: | #include <QKnxDate> |
qmake: | QT += knx |
Inherits: | QKnxFixedSizeDatapointType |
Public Functions
QKnxDate() | |
QKnxDate(const QDate &date) | |
QKnxDate(quint16 year, quint8 month, quint8 day) | |
quint8 | day() const |
quint8 | month() const |
bool | setDay(quint8 day) |
bool | setMonth(quint8 month) |
bool | setValue(const QDate &date) |
bool | setYear(quint16 year) |
QDate | value() const |
quint16 | year() const |
Reimplemented Public Functions
virtual bool | isValid() const override |
- 33 public functions inherited from QKnxDatapointType
Additional Inherited Members
- 2 protected functions inherited from QKnxDatapointType
Detailed Description
The QKnxDate class is a datapoint type for a date.
This is a fixed size datapoint type with the length of 3 bytes.
The left byte of the data holds the day as 5 bits, the middle byte holds the month as 4 bits, and the right byte holds the year as 7 bits.
Valids dates are from 1990-01-01 to 2089-12-31.
See also QKnxDatapointType.
Member Function Documentation
QKnxDate::QKnxDate()
Default constructs an instance of QKnxDate.
QKnxDate::QKnxDate(const QDate &date)
Default constructs an instance of QKnxDate.
QKnxDate::QKnxDate(quint16 year, quint8 month, quint8 day)
Default constructs an instance of QKnxDate.
quint8 QKnxDate::day() const
See also setDay().
[override virtual]
bool QKnxDate::isValid() const
Reimplemented from QKnxDatapointType::isValid().
quint8 QKnxDate::month() const
See also setMonth().
bool QKnxDate::setDay(quint8 day)
See also day().
bool QKnxDate::setMonth(quint8 month)
See also month().
bool QKnxDate::setValue(const QDate &date)
See also value().
bool QKnxDate::setYear(quint16 year)
See also year().
QDate QKnxDate::value() const
See also setValue().
quint16 QKnxDate::year() const
See also setYear().
© 2017 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.