ModelSpace
All Classes Namespaces Functions Variables Enumerations Pages
modelspace::ConfigurationWriter Class Reference

Write out script from UX to execute using set toolchain. Base class for override. More...

#include <ConfigurationWriter.h>

Inheritance diagram for modelspace::ConfigurationWriter:
Collaboration diagram for modelspace::ConfigurationWriter:

Public Member Functions

void file (const std::string &filename)
 Set the file for write and redirect output to that file.
 
std::string file ()
 
void watchNode (ImNode *target)
 Add a node to the ConfigurationWriter for tracking.
 
void unwatchNode (ImNode *target)
 Remove a node from the ConfigurationWriter for tracking.
 
void write ()
 Write watched node data to file.
 

Protected Member Functions

virtual void _setNodeConnectionSequence ()
 Set the sequence of nodes for creation and write paired connections.
 
virtual void _decomposeNodeInformation ()
 Decompose all relevant strings from the provided node and connection information.
 
virtual void _writeOutputStart ()
 Write the start of the file.
 
virtual void _writeDataValue (ImNode *node)
 Write the creation of a single node, given by node.
 
virtual void _writeDataConnection (Connection *upstream, Connection *downstream)
 Write the connection of one "Connection" to another.
 
virtual void _writeLogData ()
 Write all logged data to file.
 
virtual void _writeOutputEnd ()
 Write the end of the file output.
 

Protected Attributes

AutoDoc_autodoc_ptr
 
std::vector< ImNode * > _watched_nodes
 
std::vector< ImNode * > _sequenced_nodes
 
std::vector< std::pair< Connection *, Connection * > > _paired_connections
 
std::string _filename = "gui_config_file.py"
 

Detailed Description

Write out script from UX to execute using set toolchain. Base class for override.

Member Function Documentation

◆ _decomposeNodeInformation()

virtual void modelspace::ConfigurationWriter::_decomposeNodeInformation ( )
inlineprotectedvirtual

Decompose all relevant strings from the provided node and connection information.

Reimplemented in modelspace::ModelSpacePyConfigWriter.

◆ _setNodeConnectionSequence()

virtual void modelspace::ConfigurationWriter::_setNodeConnectionSequence ( )
inlineprotectedvirtual

Set the sequence of nodes for creation and write paired connections.

Reimplemented in modelspace::ModelSpacePyConfigWriter.

◆ _writeDataConnection()

virtual void modelspace::ConfigurationWriter::_writeDataConnection ( Connection upstream,
Connection downstream 
)
inlineprotectedvirtual

Write the connection of one "Connection" to another.

Parameters
upstreamThe data output connection (typically, but not always an output) to connect
downstreamThe data input connection (typically, but not always an input) to connect

Reimplemented in modelspace::ModelSpacePyConfigWriter.

◆ _writeDataValue()

virtual void modelspace::ConfigurationWriter::_writeDataValue ( ImNode node)
inlineprotectedvirtual

Write the creation of a single node, given by node.

Parameters
nodeThe node to write to file

Reimplemented in modelspace::ModelSpacePyConfigWriter.

◆ _writeLogData()

virtual void modelspace::ConfigurationWriter::_writeLogData ( )
inlineprotectedvirtual

Write all logged data to file.

Reimplemented in modelspace::ModelSpacePyConfigWriter.

◆ _writeOutputEnd()

virtual void modelspace::ConfigurationWriter::_writeOutputEnd ( )
inlineprotectedvirtual

Write the end of the file output.

Reimplemented in modelspace::ModelSpacePyConfigWriter.

◆ _writeOutputStart()

virtual void modelspace::ConfigurationWriter::_writeOutputStart ( )
inlineprotectedvirtual

Write the start of the file.

Reimplemented in modelspace::ModelSpacePyConfigWriter.

◆ file()

void modelspace::ConfigurationWriter::file ( const std::string &  filename)
inline

Set the file for write and redirect output to that file.

Parameters
filenameThe filename to write to
Returns
0 on success, 1 on failure
Note
Calling this function will cause the ConfigurationWriter class to begin writing its data to the provided file

◆ unwatchNode()

void modelspace::ConfigurationWriter::unwatchNode ( ImNode target)

Remove a node from the ConfigurationWriter for tracking.

Parameters
targetThe node to remove from tracking
Note
Will ignore node if its unique ID is not tracked

◆ watchNode()

void modelspace::ConfigurationWriter::watchNode ( ImNode target)

Add a node to the ConfigurationWriter for tracking.

Parameters
targetThe node to add to tracking
Note
Will ignore node if its unique ID is already tracked

The documentation for this class was generated from the following files: