QKnxStatusMode3 Class

The QKnxStatusMode3 class is a datapoint type for a status mode 3. 更多...

头: #include <QKnxStatusMode3>
qmake: QT += knx
继承: QKnxFixedSizeDatapointType

公共类型

enum class Mode { Zero, One, Two, Unknown }
enum Status { A, B, C, D, E }
flags StatusFlags

公共函数

QKnxStatusMode3 (QKnxStatusMode3::Mode mode , QKnxStatusMode3::StatusFlags statusFlags )
QKnxStatusMode3 ()
bool isSet (QKnxStatusMode3::Status status ) const
QKnxStatusMode3::Mode mode () const
bool removeStatus (QKnxStatusMode3::Status status )
bool setMode (QKnxStatusMode3::Mode mode )
bool setStatus (QKnxStatusMode3::Status status )
bool setStatusFlags (QKnxStatusMode3::StatusFlags statusFlags )
QKnxStatusMode3::StatusFlags statusFlags () const

重实现公共函数

virtual bool isValid () const override

详细描述

This datapoint type holds information about which status flags (from A to E ) are set and which mode (from Zero to 2 ) is active. Valid values are from All set and Mode 0 to All cleared and Mode 2 .

This is a fixed size datapoint type with the length of 1 byte.

另请参阅 QKnxDatapointType and Qt KNX Datapoint Type Classes .

成员类型文档编制

enum class QKnxStatusMode3:: Mode

This enum holds information about which mode is active.

常量 描述
QKnxStatusMode3::Mode::Zero 0x01 Mode 0 is active.
QKnxStatusMode3::Mode::One 0x02 Mode 1 is active.
QKnxStatusMode3::Mode::Two 0x04 Mode 2 is active.
QKnxStatusMode3::Mode::Unknown 0x08 It is not possible to determine which mode is active.

enum QKnxStatusMode3:: Status
flags QKnxStatusMode3:: StatusFlags

This enum indicates whether a status flag is set ( 0 ) or cleared ( 1 ).

常量 描述
QKnxStatusMode3::A 0x01 Status value A.
QKnxStatusMode3::B 0x02 Status value B.
QKnxStatusMode3::C 0x04 Status value C.
QKnxStatusMode3::D 0x08 Status value D.
QKnxStatusMode3::E 0x0a Status value E.

The StatusFlags type is a typedef for QFlags <Status>. It stores an OR combination of Status values.

成员函数文档编制

QKnxStatusMode3:: QKnxStatusMode3 ( QKnxStatusMode3::Mode mode , QKnxStatusMode3::StatusFlags statusFlags )

Creates a fixed size datapoint type with the mode set to mode and the status flags set to statusFlags .

QKnxStatusMode3:: QKnxStatusMode3 ()

Creates a fixed size datapoint type with the mode set to 未知 and the status flags left empty.

bool QKnxStatusMode3:: isSet ( QKnxStatusMode3::Status status ) const

返回 true if the status flag status is set in the status flags.

[override virtual] bool QKnxStatusMode3:: isValid () const

重实现: QKnxDatapointType::isValid () const.

QKnxStatusMode3::Mode QKnxStatusMode3:: mode () const

Returns the mode stored in the datapoint type.

另请参阅 setMode ().

bool QKnxStatusMode3:: removeStatus ( QKnxStatusMode3::Status status )

Removes the status status from the status flags.

返回 true if the status was removed; otherwise returns false .

bool QKnxStatusMode3:: setMode ( QKnxStatusMode3::Mode mode )

Sets the mode stored in the datapoint type to mode .

If the value is outside the allowed range, returns false and does not set the value.

另请参阅 mode ().

bool QKnxStatusMode3:: setStatus ( QKnxStatusMode3::Status status )

Sets the status status in the status flags.

返回 true if the status was set; otherwise returns false .

bool QKnxStatusMode3:: setStatusFlags ( QKnxStatusMode3::StatusFlags statusFlags )

设置 statusFlags stored in the datapoint type to statusFlags .

返回 true if the value was set; otherwise returns false .

另请参阅 statusFlags ().

QKnxStatusMode3::StatusFlags QKnxStatusMode3:: statusFlags () const

Returns the status flags stored in the datapoint type.

另请参阅 setStatusFlags ().