Storm 1.11.1.1
A Modern Probabilistic Model Checker
Loading...
Searching...
No Matches
ClockVariable.cpp
Go to the documentation of this file.
2
6
7namespace storm {
8namespace prism {
9ClockVariable::ClockVariable(storm::expressions::Variable const& variable, bool observable, std::string const& filename, uint_fast64_t lineNumber)
10 : Variable(variable, variable.getManager().rational(storm::utility::zero<storm::RationalNumber>()), observable, filename, lineNumber) {
11 // Nothing to do here.
12}
13
15 if (!this->hasInitialValue()) {
16 this->setInitialValueExpression(this->getExpressionVariable().getManager().rational(storm::utility::zero<storm::RationalNumber>()));
17 }
18}
19
20std::ostream& operator<<(std::ostream& stream, ClockVariable const& variable) {
21 stream << variable.getName() << ": clock" << ";";
22 return stream;
23}
24
25} // namespace prism
26} // namespace storm
virtual void createMissingInitialValue() override
Sets a missing initial value (note that for clock variables, this is always zero)
storm::expressions::Variable const & getExpressionVariable() const
Retrieves the expression variable associated with this variable.
Definition Variable.cpp:40
void setInitialValueExpression(storm::expressions::Expression const &initialValueExpression)
Sets the expression defining the initial value of the variable.
Definition Variable.cpp:36
std::string const & getName() const
Retrieves the name of the variable.
Definition Variable.cpp:24
bool hasInitialValue() const
Retrieves whether the variable has an initial value.
Definition Variable.cpp:28