QOpcUaReadResult#

This class stores the result of a read operation. More

Inheritance diagram of PySide6.QtOpcUa.QOpcUaReadResult

Synopsis#

Functions#

Detailed Description#

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 readNodeAttributesFinished() signal and contain the result of a read operation that was part of a readNodeAttributes() request.

class PySide6.QtOpcUa.QOpcUaReadResult#

PySide6.QtOpcUa.QOpcUaReadResult(other)

Parameters

otherPySide6.QtOpcUa.QOpcUaReadResult

Constructs a read result from other.

PySide6.QtOpcUa.QOpcUaReadResult.attribute()#
Return type

NodeAttribute

Returns the attribute id.

See also

setAttribute()

PySide6.QtOpcUa.QOpcUaReadResult.indexRange()#
Return type

str

Returns the index range.

See also

setIndexRange()

PySide6.QtOpcUa.QOpcUaReadResult.nodeId()#
Return type

str

Returns the node id.

See also

setNodeId()

PySide6.QtOpcUa.QOpcUaReadResult.serverTimestamp()#
Return type

PySide6.QtCore.QDateTime

Returns the server timestamp for value() .

PySide6.QtOpcUa.QOpcUaReadResult.setAttribute(attribute)#
Parameters

attributeNodeAttribute

Sets the attribute id to attribute.

See also

attribute()

PySide6.QtOpcUa.QOpcUaReadResult.setIndexRange(indexRange)#
Parameters

indexRange – str

Sets the index range to indexRange.

See also

indexRange()

PySide6.QtOpcUa.QOpcUaReadResult.setNodeId(nodeId)#
Parameters

nodeId – str

Sets the node id to nodeId.

See also

nodeId()

PySide6.QtOpcUa.QOpcUaReadResult.setServerTimestamp(serverTimestamp)#
Parameters

serverTimestampPySide6.QtCore.QDateTime

Sets the server timestamp to serverTimestamp.

PySide6.QtOpcUa.QOpcUaReadResult.setSourceTimestamp(sourceTimestamp)#
Parameters

sourceTimestampPySide6.QtCore.QDateTime

Sets the source timestamp to sourceTimestamp.

PySide6.QtOpcUa.QOpcUaReadResult.setStatusCode(statusCode)#
Parameters

statusCodeUaStatusCode

Sets the status code to statusCode.

See also

statusCode()

PySide6.QtOpcUa.QOpcUaReadResult.setValue(value)#
Parameters

value – object

Sets the value to value.

See also

value()

PySide6.QtOpcUa.QOpcUaReadResult.sourceTimestamp()#
Return type

PySide6.QtCore.QDateTime

Returns the source timestamp for value() .

PySide6.QtOpcUa.QOpcUaReadResult.statusCode()#
Return type

UaStatusCode

Returns the status code for this element. If the status code is not Good , the value and the timestamps are invalid.

See also

setStatusCode()

PySide6.QtOpcUa.QOpcUaReadResult.value()#
Return type

object

Returns the value.

See also

setValue()