Storm 2.0.0.3
A Modern Probabilistic Model Checker
Loading...
Searching...
No Matches
CuddSettings.cpp
Go to the documentation of this file.
2
4
9
10namespace storm {
11namespace settings {
12namespace modules {
13
14const std::string CuddSettings::moduleName = "cudd";
15const std::string CuddSettings::precisionOptionName = "precision";
16const std::string CuddSettings::maximalMemoryOptionName = "maxmem";
17
19 this->addOption(storm::settings::OptionBuilder(moduleName, precisionOptionName, true, "Sets the precision used by Cudd.")
20 .setIsAdvanced()
22 "value", "The precision up to which to constants are considered to be different.")
23 .setDefaultValueDouble(1e-15)
25 .build())
26 .build());
27
28 this->addOption(
29 storm::settings::OptionBuilder(moduleName, maximalMemoryOptionName, true, "Sets the upper bound of memory available to Cudd in MB.")
30 .setIsAdvanced()
31 .addArgument(storm::settings::ArgumentBuilder::createUnsignedIntegerArgument("value", "The memory available to Cudd (0 means unlimited).")
32 .setDefaultValueUnsignedInteger(4096)
33 .build())
34 .build());
35}
36
38 return this->getOption(precisionOptionName).getArgumentByName("value").getValueAsDouble();
39}
40
41uint_fast64_t CuddSettings::getMaximalMemory() const {
42 return this->getOption(maximalMemoryOptionName).getArgumentByName("value").getValueAsUnsignedInteger();
43}
44
45} // namespace modules
46} // namespace settings
47} // namespace storm
virtual uint_fast64_t getValueAsUnsignedInteger() const =0
Retrieves the value of this argument as an unsigned integer.
virtual double getValueAsDouble() const =0
Retrieves the value of this argument as a double.
static ArgumentBuilder createUnsignedIntegerArgument(std::string const &name, std::string const &description)
Creates an unsigned integer argument with the given parameters.
static ArgumentBuilder createDoubleArgument(std::string const &name, std::string const &description)
Creates a double argument with the given parameters.
static std::shared_ptr< ArgumentValidator< double > > createDoubleRangeValidatorIncluding(double lowerBound, double upperBound)
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
static const std::string moduleName
CuddSettings()
Creates a new set of CUDD settings.
uint_fast64_t getMaximalMemory() const
Retrieves the maximal amount of memory (in megabytes) that CUDD can occupy.
double getConstantPrecision() const
Retrieves the precision that CUDD is supposed to use for distinguishing constants.
ModuleSettings(std::string const &moduleName)
Constructs a new settings object.
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.
The contract of a DD backend.