Storm
A Modern Probabilistic Model Checker
Loading...
Searching...
No Matches
Smt2SmtSolverSettings.cpp
Go to the documentation of this file.
2
4
9
10namespace storm {
11namespace settings {
12namespace modules {
13
14const std::string Smt2SmtSolverSettings::moduleName = "smt2";
15const std::string Smt2SmtSolverSettings::solverCommandOption = "solvercommand";
16const std::string Smt2SmtSolverSettings::exportScriptOption = "exportscript";
17
19 this->addOption(storm::settings::OptionBuilder(moduleName, solverCommandOption, true,
20 "If set, this command is used to call the solver and to let the solver know that it should read SMT-LIBv2 "
21 "commands from standard input. If not set, only a SMT-LIB script file might be exported.")
22 .setIsAdvanced()
23 .addArgument(storm::settings::ArgumentBuilder::createStringArgument("command", "path to the solver + command line arguments.")
24 .setDefaultValueString("")
25 .build())
26 .build());
27
28 this->addOption(storm::settings::OptionBuilder(moduleName, exportScriptOption, true, "If set, the SMT-LIBv2 script will be exportet to this file.")
29 .setIsAdvanced()
31 "path", "path and filename to the location where the script file should be exported to.")
32 .setDefaultValueString("")
33 .build())
34 .build());
35}
36
38 return this->getOption(solverCommandOption).getHasOptionBeenSet();
39}
40
42 return this->getOption(solverCommandOption).getArgumentByName("command").getValueAsString();
43}
44
46 return this->getOption(exportScriptOption).getHasOptionBeenSet();
47}
48
50 return this->getOption(exportScriptOption).getArgumentByName("path").getValueAsString();
51}
52
55 // TODO check if paths are valid
56 }
57 return true;
58}
59
60} // namespace modules
61} // namespace settings
62} // namespace storm
virtual std::string getValueAsString() const =0
Retrieves the value of this argument as a string.
static ArgumentBuilder createStringArgument(std::string const &name, std::string const &description)
Creates a string argument with the given parameters.
This class provides the interface to create an option...
ArgumentBase const & getArgumentByName(std::string const &argumentName) const
Returns a reference to the argument with the specified long name.
Definition Option.cpp:79
bool getHasOptionBeenSet() const
Retrieves whether the option has been set.
Definition Option.cpp:125
This is the base class of the settings for a particular module.
void addOption(std::shared_ptr< Option > const &option)
Adds and registers the given option.
Option & getOption(std::string const &longName)
Retrieves the option with the given long name.
bool isSolverCommandSet() const
Retrieves whether the solver command has been set.
Smt2SmtSolverSettings()
Creates a new set of SmtlibSmtSolver settings that is managed by the given manager.
bool check() const override
Checks whether the settings are consistent.
bool isExportSmtLibScriptSet() const
Retrieves whether the SMT-LIBv2 script should be exportet to a file.
std::string getSolverCommand() const
Retrieves the solver command i.e.
std::string getExportSmtLibScriptPath() const
Retrieves the path where the SMT-LIBv2 script file should be exportet to.
LabParser.cpp.
Definition cli.cpp:18