0.3.0
Loading...
Searching...
No Matches
NAV::flow Namespace Reference

Functions

void ApplyChanges ()
 Signals that there have been changes to the flow.
 
void DiscardChanges ()
 Discards the unsaved changes flag. Does not really discard the changes.
 
std::filesystem::path GetConfigPath ()
 Get the path where config files are searched.
 
std::string GetCurrentFilename ()
 Get the current filename of the open flow.
 
std::filesystem::path GetFlowPath ()
 Get the path where flow files are searched.
 
std::filesystem::path GetInputPath ()
 Get the path where data files are searched.
 
std::filesystem::path GetOutputPath ()
 Get the path where logs and outputs are stored.
 
std::filesystem::path GetProgramRootPath ()
 Get the program root path.
 
bool HasUnsavedChanges ()
 Checks if the currently open flow has unsaved changes.
 
bool LoadFlow (const std::string &filepath)
 Loads the flow from the specified file.
 
bool LoadJson (const json &j, bool requestNewIds=false)
 Loads the nodes and links from the specified json object.
 
void SaveFlow (GlobalActions &globalAction)
 Saves the current flow into a file.
 
void SaveFlowAs (const std::string &filepath)
 Saves the current flow into the specified file.
 
void SetCurrentFilename (const std::string &newFilename)
 Set the current filename of the open flow.
 
void SetOutputPath ()
 Set the path where logs and outputs are stored.
 
void SetProgramRootPath (const std::filesystem::path &newRootPath)
 Set the program root path.
 

Variables

int loadingFrameCount
 Frame Count when changes were loaded to prevent nodes moving from triggering unsaved changes.
 
bool saveLastActions
 Whether actions should be saved to the last actions list.
 

Function Documentation

◆ ApplyChanges()

void NAV::flow::ApplyChanges ( )

Signals that there have been changes to the flow.

Definition at line 442 of file FlowManager.cpp.

◆ DiscardChanges()

void NAV::flow::DiscardChanges ( )

Discards the unsaved changes flag. Does not really discard the changes.

Definition at line 455 of file FlowManager.cpp.

◆ GetConfigPath()

std::filesystem::path NAV::flow::GetConfigPath ( )

Get the path where config files are searched.

Definition at line 563 of file FlowManager.cpp.

◆ GetCurrentFilename()

std::string NAV::flow::GetCurrentFilename ( )

Get the current filename of the open flow.

Returns
Current filename of the open flow

Definition at line 460 of file FlowManager.cpp.

◆ GetFlowPath()

std::filesystem::path NAV::flow::GetFlowPath ( )

Get the path where flow files are searched.

Definition at line 546 of file FlowManager.cpp.

◆ GetInputPath()

std::filesystem::path NAV::flow::GetInputPath ( )

Get the path where data files are searched.

Definition at line 529 of file FlowManager.cpp.

◆ GetOutputPath()

std::filesystem::path NAV::flow::GetOutputPath ( )

Get the path where logs and outputs are stored.

Definition at line 481 of file FlowManager.cpp.

◆ GetProgramRootPath()

std::filesystem::path NAV::flow::GetProgramRootPath ( )

Get the program root path.

Returns
The path to the program root

Definition at line 470 of file FlowManager.cpp.

◆ HasUnsavedChanges()

bool NAV::flow::HasUnsavedChanges ( )

Checks if the currently open flow has unsaved changes.

Returns
True if there are changes

Definition at line 437 of file FlowManager.cpp.

◆ LoadFlow()

bool NAV::flow::LoadFlow ( const std::string & filepath)

Loads the flow from the specified file.

Parameters
[in]filepathPath where to load the flow
Returns
Whether the load was successfull

Definition at line 135 of file FlowManager.cpp.

◆ LoadJson()

bool NAV::flow::LoadJson ( const json & j,
bool requestNewIds = false )

Loads the nodes and links from the specified json object.

Parameters
[in]jJson object containing nodes and links to load
[in]requestNewIdsSet this true if the loaded nodes should receive new Ids (copy). False if the Ids should stay (cut/load)
Returns
Whether the load was successfull

Definition at line 213 of file FlowManager.cpp.

◆ SaveFlow()

void NAV::flow::SaveFlow ( GlobalActions & globalAction)

Saves the current flow into a file.

Parameters
[out]globalActionIf currentfilename is empty this will be returned as GlobalActions::SaveAs

Definition at line 63 of file FlowManager.cpp.

◆ SaveFlowAs()

void NAV::flow::SaveFlowAs ( const std::string & filepath)

Saves the current flow into the specified file.

Parameters
[in]filepathPath where to save the flow

Definition at line 75 of file FlowManager.cpp.

◆ SetCurrentFilename()

void NAV::flow::SetCurrentFilename ( const std::string & newFilename)

Set the current filename of the open flow.

Parameters
[in]newFilenameNew filename of the flow

Definition at line 465 of file FlowManager.cpp.

◆ SetOutputPath()

void NAV::flow::SetOutputPath ( )

Set the path where logs and outputs are stored.

Definition at line 503 of file FlowManager.cpp.

◆ SetProgramRootPath()

void NAV::flow::SetProgramRootPath ( const std::filesystem::path & newRootPath)

Set the program root path.

Parameters
[in]newRootPathThe new program root path

Definition at line 475 of file FlowManager.cpp.

Variable Documentation

◆ loadingFrameCount

int NAV::flow::loadingFrameCount

Frame Count when changes were loaded to prevent nodes moving from triggering unsaved changes.

Definition at line 59 of file FlowManager.cpp.

◆ saveLastActions

bool NAV::flow::saveLastActions

Whether actions should be saved to the last actions list.

Definition at line 58 of file FlowManager.cpp.