Browse Source

add const

Former-commit-id: e8c2cc6f29
tempestpy_adaptions
ThomasH 8 years ago
parent
commit
b799963016
  1. 2
      src/storage/gspn/GSPN.cpp
  2. 2
      src/storage/gspn/GSPN.h

2
src/storage/gspn/GSPN.cpp

@ -57,7 +57,7 @@ namespace storm {
return std::make_pair<bool, std::shared_ptr<storm::gspn::TimedTransition<GSPN::RateType>> const>(false, nullptr);
}
std::pair<bool, std::shared_ptr<storm::gspn::ImmediateTransition<GSPN::WeightType>> const> GSPN::getImmediateTransition(std::string id) const {
std::pair<bool, std::shared_ptr<storm::gspn::ImmediateTransition<GSPN::WeightType>> const> GSPN::getImmediateTransition(std::string const& id) const {
for (auto& trans : immediateTransitions) {
if (id.compare(trans->getName()) == 0) {
return std::make_pair<bool, std::shared_ptr<storm::gspn::ImmediateTransition<GSPN::WeightType>> const>(true, static_cast<std::shared_ptr<storm::gspn::ImmediateTransition<GSPN::WeightType>> const>(trans));

2
src/storage/gspn/GSPN.h

@ -101,7 +101,7 @@ namespace storm {
* If the first element is true, then the second element is the wanted transition.
* If the first element is false, then the second element is the nullptr.
*/
std::pair<bool, std::shared_ptr<storm::gspn::ImmediateTransition<GSPN::WeightType>> const> getImmediateTransition(std::string id) const;
std::pair<bool, std::shared_ptr<storm::gspn::ImmediateTransition<GSPN::WeightType>> const> getImmediateTransition(std::string const& id) const;
/*!
* Returns the transition with the corresponding id.

Loading…
Cancel
Save