This class provides serialization of global names for a Workspace-based application.
#include <Workspace/DataExecution/Serialization/globalnameserializer.h>
|
| GlobalNameSerializer () |
|
| ~GlobalNameSerializer () override |
|
bool | checkIntegrityOfGlobalNameFile (const SerializedItem &item, QStringList *duplicatedNameList=nullptr) |
|
int | getDuplicateGlobalNameCount (QStringList &duplicatedNames, const QStringList &descriptions) |
|
const QString & | getGlobalNamePathName () const |
|
bool | loadGlobalNamesFromFile (Workspace &workspace, const QString &fileName) |
|
bool | loadGlobalNamesFromFile (Workspace &workspace, const QStringList &globalNames, const QString &fileName) |
|
bool | loadGlobalNamesFromFile (Workspace &workspace, const QStringList &globalNames, const QString &fileName, QStringList &ignoredNamesOut) |
|
bool | loadGlobalNamesFromItem (Workspace &workspace, const QStringList &globalNames, const SerializedItem &item) |
|
bool | loadGlobalNamesFromItem (Workspace &workspace, const QStringList &globalNames, const SerializedItem &item, QStringList &ignoredNamesOut) |
|
bool | loadInputsFromItem (Workspace &workspace, const QStringList &inputNames, const SerializedItem &item) |
|
bool | loadInputsFromItem (Workspace &workspace, const QStringList &inputNames, const SerializedItem &item, QStringList &ignoredNamesOut) |
|
bool | saveGlobalNamesToFile (Workspace &workspace, const QStringList &globalNames, const QString &fileName, bool savePreferedWidget=true) |
|
bool | saveGlobalNamesToItem (Workspace &workspace, const QStringList &globalNames, SerializedItem &item, bool savePreferedWidget=true) |
|
bool | saveInputsToItem (Workspace &workspace, const QStringList &inputNames, SerializedItem &item, bool savePreferedWidget=true) |
|
void | setGlobalNamePathName (const QString &newPathName) |
|
◆ GlobalNameSerializer()
◆ ~GlobalNameSerializer()
◆ checkIntegrityOfGlobalNameFile()
◆ disableWarningAndErrorLogging
void disableWarningAndErrorLogging |
( |
| ) |
|
|
slot |
◆ displayErrorMessage
void displayErrorMessage |
( |
const QString & |
msg | ) |
|
|
signal |
Emitted when an error occurs.
◆ displayStatusMessage
void displayStatusMessage |
( |
const QString & |
msg | ) |
|
|
signal |
Emitted when a new status message is ready.
◆ displayWarningMessage
void displayWarningMessage |
( |
const QString & |
msg | ) |
|
|
signal |
Emitted when a warning occurs.
◆ getAllGlobalNamesFromWidgetTree()
QStringList getAllGlobalNamesFromWidgetTree |
( |
const QWidget * |
w | ) |
|
|
static |
◆ getDuplicateGlobalNameCount()
◆ getGlobalNamePathName()
const QString & getGlobalNamePathName |
( |
| ) |
const |
◆ loadGlobalNamesFromFile() [1/3]
bool loadGlobalNamesFromFile |
( |
Workspace & |
workspace, |
|
|
const QString & |
fileName |
|
) |
| |
This is an overloaded function that loads all the global names from file.
◆ loadGlobalNamesFromFile() [2/3]
bool loadGlobalNamesFromFile |
( |
Workspace & |
workspace, |
|
|
const QStringList & |
globalNames, |
|
|
const QString & |
fileName |
|
) |
| |
Load the value of the supplied global names from a file.
- Parameters
-
workspace | The root workspace to load the global name values into. |
globalNames | The list of global names to load. |
fileName | The file to load from. |
◆ loadGlobalNamesFromFile() [3/3]
Load the value of the supplied global names from a file.
- Parameters
-
| workspace | The root workspace to load the global name values into. |
| globalNames | The list of global names to load. |
| fileName | The file to load from. |
[out] | ignoredNamesOut | If the input globalNames list is not empty then ignoredNamesOut is populated with any names encountered that are not in this list |
◆ loadGlobalNamesFromItem() [1/2]
Load the value of the supplied global names from a SerializedItem.
- Parameters
-
workspace | The root workspace to load the global name values into. |
globalNames | The list of global names to load. |
item | The QDomElement to load from. |
◆ loadGlobalNamesFromItem() [2/2]
Load the value of the supplied global names from a SerializedItem.
- Parameters
-
| workspace | The root workspace to load the global name values into. |
| globalNames | The list of global names to load. |
| item | The QDomElement to load from. |
[out] | ignoredNamesOut | If the input globalNames list is not empty then ignoredNamesOut is populated with any names encountered that are not in this list |
◆ loadInputsFromItem() [1/2]
Load the value of the supplied input names from a SerializedItem.
- Parameters
-
workspace | The root workspace to load the input values into. |
inputNames | The list of global names to load. |
item | The QDomElement to load from. |
◆ loadInputsFromItem() [2/2]
Load the value of the supplied input names from a SerializedItem.
- Parameters
-
| workspace | The root workspace to load the input values into. |
| inputNames | The list of global names to load. |
| item | The QDomElement to load from. |
[out] | ignoredNamesOut | If the input inputNames list is not empty then ignoredNamesOut is populated with any names encountered that are not in this list |
◆ logErrorMessage
void logErrorMessage |
( |
const QString & |
msg | ) |
|
|
slot |
◆ logStatusMessage
void logStatusMessage |
( |
const QString & |
msg | ) |
|
|
slot |
◆ logWarningMessage
void logWarningMessage |
( |
const QString & |
msg | ) |
|
|
slot |
◆ saveGlobalNamesToFile()
bool saveGlobalNamesToFile |
( |
Workspace & |
workspace, |
|
|
const QStringList & |
globalNames, |
|
|
const QString & |
fileName, |
|
|
bool |
savePreferedWidget = true |
|
) |
| |
Serialize the supplied list of global names to a file.
- Parameters
-
workspace | The root workspace to perform the save on. |
globalNames | The list of global names to save. |
fileName | The name of the file to save to. |
savePreferedWidget | Include the preferredwidget property of the global name. |
◆ saveGlobalNamesToItem()
Serialize the supplied list of global names to a SerializedItem.
- Parameters
-
workspace | The root workspace to perform the save on. |
globalNames | The list of global names to save. |
item | The SerializedItem to save the global names to. |
savePreferedWidget | Include the preferredwidget property of the global name. |
◆ saveInputsToItem()
Serialize the supplied list of input names to a SerializedItem.
- Parameters
-
workspace | The root workspace to perform the save on. |
inputNames | The list of input names to save. |
item | The SerializedItem to save the global names to. |
savePreferedWidget | Include the preferredwidget property of the global name. |
◆ setGlobalNamePathName()
void setGlobalNamePathName |
( |
const QString & |
newPathName | ) |
|