PySide6.QtRemoteObjects.QRemoteObjectAbstractPersistedStore¶
- class QRemoteObjectAbstractPersistedStore¶
A class which provides the methods for setting PROP values of a replica to value they had the last time the replica was used. More…
Inherited by:
QRemoteObjectSettingsStore
Synopsis¶
Methods¶
def
__init__()
Virtual methods¶
def
saveProperties()
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¶
This can be used to provide a “reasonable” value to be displayed until the connection to the source is established and current values are available.
This class must be overridden to provide an implementation for saving (
saveProperties
) and restoring (restoreProperties
) PROP values. The derived type can then be set for a node, and any replica acquired from that node will then automatically store PERSISTED properties when the replica destructor is called, and retrieve the values when the replica is instantiated.Constructs a
QRemoteObjectAbstractPersistedStore
with the givenparent
. The default value ofparent
isNone
.- abstract restoreProperties(repName, repSig)¶
- Parameters:
repName – str
repSig –
QByteArray
- Return type:
.list of QVariant
This method will be provided the replica class’s
repName
andrepSig
when the replica is being initialized. It is the responsibility of the inheriting class to get the last values persisted bysaveProperties
and return them. An empty QVariantList should be returned if no values are available.See also
- abstract saveProperties(repName, repSig, values)¶
- Parameters:
repName – str
repSig –
QByteArray
values – .list of QVariant
This method will be provided the replica class’s
repName
,repSig
and the list ofvalues
that PERSISTED properties have when the replica destructor was called. It is the responsibility of the inheriting class to store the information in a manner consistent forrestoreProperties
to retrieve.See also