UnCoVer (Using Coverability for Verification)
|
This class generates Scenario object from their string identifier (without initializing them). More...
#include <ScenarioLoader.h>
Public Member Functions | |
ScenarioLoader () | |
Generates a new ScenarioLoader object. More... | |
virtual | ~ScenarioLoader () |
Destroys this instance of ScenarioLoader. | |
basic_types::Scenario_up | getScenario (string ident) const |
Generates a Scenario object specified by the given string without initializing it. More... | |
basic_types::Scenario_up | getScenarioByName (string name) const |
Generates a Scenario object specified by the given name without initializing it. More... | |
basic_types::Scenario_up | getScenarioByID (unsigned int id) const |
Generates a Scenario object specified by the given ID without initializing it. More... | |
void | getScenarioList (std::ostream &ost, string separator=",") const |
Print a list of all available scenarios to the given stream using the given separator. More... | |
Private Member Functions | |
void | initNameToIDMapping () |
Fills the scnNameToIDMapping with the appropriate (hard coded) values. | |
Private Attributes | |
unordered_map< string, unsigned int > | scnNameToIDMapping |
A mapping from scenario names (long and short) to an unique identifier. | |
unordered_set< string > | firstNames |
A set storing all names which should be displayed first when printing the scenario list. | |
This class generates Scenario object from their string identifier (without initializing them).
ScenarioLoader | ( | ) |
Generates a new ScenarioLoader object.
No further initialization is required.
Scenario_up getScenario | ( | string | ident | ) | const |
Generates a Scenario object specified by the given string without initializing it.
It is first checked if the given string is a defined name and then if it is an ID. If neither is the case, nullptr is returned.
ident | the name or ID of the desired Scenario |
Scenario_up getScenarioByID | ( | unsigned int | id | ) | const |
Generates a Scenario object specified by the given ID without initializing it.
Returns nullptr if there is no Scenario with the given ID.
id | the ID of the desired Scenario |
Scenario_up getScenarioByName | ( | string | name | ) | const |
Generates a Scenario object specified by the given name without initializing it.
Returns nullptr if there is no Scenario with the given name.
name | the name of the desired Scenario |
void getScenarioList | ( | std::ostream & | ost, |
string | separator = "," |
||
) | const |
Print a list of all available scenarios to the given stream using the given separator.
ost | the stream where the scenario list will be printed |
separator | the separator used between every element of the list |