Browse Source

Use template for DFTTraceSimulator

main
Matthias Volk 4 years ago
parent
commit
344ba353e0
No known key found for this signature in database GPG Key ID: 83A57678F739FCD3
  1. 12
      src/storm-dft/simulator/DFTTraceSimulator.cpp
  2. 2
      src/storm-dft/simulator/DFTTraceSimulator.h

12
src/storm-dft/simulator/DFTTraceSimulator.cpp

@ -73,6 +73,12 @@ namespace storm {
} }
} }
template<>
double DFTTraceSimulator<storm::RationalFunction>::randomStep() {
STORM_LOG_THROW(false, storm::exceptions::NotSupportedException, "Simulation not support for parametric DFTs.");
}
template<typename ValueType> template<typename ValueType>
bool DFTTraceSimulator<ValueType>::step(storm::dft::storage::FailableElements::const_iterator nextFailElement) { bool DFTTraceSimulator<ValueType>::step(storm::dft::storage::FailableElements::const_iterator nextFailElement) {
if (nextFailElement == state->getFailableElements().end()) { if (nextFailElement == state->getFailableElements().end()) {
@ -118,7 +124,13 @@ namespace storm {
return false; return false;
} }
template<>
bool DFTTraceSimulator<storm::RationalFunction>::simulateCompleteTrace(double timebound) {
STORM_LOG_THROW(false, storm::exceptions::NotSupportedException, "Simulation not support for parametric DFTs.");
}
template class DFTTraceSimulator<double>; template class DFTTraceSimulator<double>;
template class DFTTraceSimulator<storm::RationalFunction>;
} }
} }
} }

2
src/storm-dft/simulator/DFTTraceSimulator.h

@ -83,7 +83,7 @@ namespace storm {
storm::storage::DFTStateGenerationInfo const& stateGenerationInfo; storm::storage::DFTStateGenerationInfo const& stateGenerationInfo;
// Generator for creating next state in DFT // Generator for creating next state in DFT
storm::generator::DftNextStateGenerator<double> generator; storm::generator::DftNextStateGenerator<ValueType> generator;
// Current state // Current state
DFTStatePointer state; DFTStatePointer state;

|||||||
100:0
Loading…
Cancel
Save