class QOpcUaHistoryData

This class stores historical data values from a node. More

Added in version 6.3.

Synopsis

Methods

Note

This documentation may contain snippets that were automatically translated from C++ to Python. We always welcome contributions to the snippet translation. If you see an issue with the translation, you can also let us know by creating a ticket on https:/bugreports.qt.io/projects/PYSIDE

Detailed Description

When a request to read history data is being handled, instances of this class are used to store information about which node has been read, its values and the status code. The finished signal of a history read request will return a list of QOpcUaHistoryData objects which can be parsed to review the results of the request.

__init__()

Constructs an invalid history data item.

__init__(other)
Parameters:

otherQOpcUaHistoryData

Constructs a history data item from other.

__init__(nodeId)
Parameters:

nodeId – str

Constructs a history data item and stores which node it corresponds to.

addValue(value)
Parameters:

valueQOpcUaDataValue

Adds a data value object given by value.

count()
Return type:

int

Returns the number of available data value objects.

nodeId()
Return type:

str

Returns the nodeId of the node whose data has been stored.

See also

setNodeId()

result()
Return type:

.list of QOpcUaDataValue

Returns the list of data value objects which contain the results of the history read request.

setNodeId(nodeId)
Parameters:

nodeId – str

Sets the nodeId to nodeId.

See also

nodeId()

setStatusCode(statusCode)
Parameters:

statusCodeUaStatusCode

Sets the status code to statusCode.

See also

statusCode()

statusCode()
Return type:

UaStatusCode

Returns the status code which indicates if an error occurred while fetching the history data.

See also

setStatusCode()

swap(other)
Parameters:

otherQOpcUaHistoryData

Swaps this data value instance with other. This function is very fast and never fails.