This class stores the result of a read operation. 更多...
| 頭: | #include <QOpcUaReadResult> |
| qmake: | QT += opcua |
| QOpcUaReadResult (const QOpcUaReadResult & other ) | |
| QOpcUaReadResult & | operator= (const QOpcUaReadResult & rhs ) |
| QOpcUa::NodeAttribute | attribute () const |
| QString | indexRange () const |
| QString | nodeId () const |
| QDateTime | serverTimestamp () const |
| void | setAttribute (QOpcUa::NodeAttribute attribute ) |
| void | setIndexRange (const QString & indexRange ) |
| void | setNodeId (const QString & nodeId ) |
| void | setServerTimestamp (const QDateTime & serverTimestamp ) |
| void | setSourceTimestamp (const QDateTime & sourceTimestamp ) |
| void | setStatusCode (QOpcUa::UaStatusCode statusCode ) |
| void | setValue (const QVariant & value ) |
| QDateTime | sourceTimestamp () const |
| QOpcUa::UaStatusCode | statusCode () const |
| QVariant | value () const |
A read operation on an OPC UA server returns the value and timestamps which describe when a value was generated by the source and when the server obtained it. It also returns a status code which describes if the value could be read and if not, for what reason the read has failed.
In addition to the data returned by the server, this class also contains the node id, the attribute and the index range from the request to enable a client to match the result with a request.
Objects of this class are returned in the QOpcUaClient::readNodeAttributesFinished () signal and contain the result of a read operation that was part of a QOpcUaClient::readNodeAttributes () request.
另請參閱 QOpcUaClient::readNodeAttributes (), QOpcUaClient::readNodeAttributesFinished (),和 QOpcUaReadItem .
Constructs a read result from other .
設置值從 rhs in this read result.
Returns the attribute id.
另請參閱 setAttribute ().
Returns the index range.
另請參閱 setIndexRange ().
Returns the node id.
另請參閱 setNodeId ().
Returns the server timestamp for value ().
另請參閱 setServerTimestamp ().
Sets the attribute id to attribute .
另請參閱 attribute ().
Sets the index range to indexRange .
另請參閱 indexRange ().
Sets the node id to nodeId .
另請參閱 nodeId ().
Sets the server timestamp to serverTimestamp .
另請參閱 serverTimestamp ().
Sets the source timestamp to sourceTimestamp .
另請參閱 sourceTimestamp ().
Sets the status code to statusCode .
另請參閱 statusCode ().
Sets the value to value .
另請參閱 value ().
Returns the source timestamp for value ().
另請參閱 setSourceTimestamp ().
Returns the status code for this element. If the status code is not Good , the value and the timestamps are invalid.
另請參閱 setStatusCode ().
Returns the value.
另請參閱 setValue ().