|
|
@ -4,48 +4,38 @@ namespace storm { |
|
|
|
namespace jani { |
|
|
|
|
|
|
|
std::ostream& operator<<(std::ostream& stream, ModelType const& type) { |
|
|
|
return stream << to_string(type); |
|
|
|
} |
|
|
|
|
|
|
|
std::string to_string(ModelType const& type) { |
|
|
|
switch (type) { |
|
|
|
case ModelType::UNDEFINED: |
|
|
|
stream << "undefined"; |
|
|
|
break; |
|
|
|
return "undefined"; |
|
|
|
case ModelType::LTS: |
|
|
|
stream << "lts"; |
|
|
|
break; |
|
|
|
return "lts"; |
|
|
|
case ModelType::DTMC: |
|
|
|
stream << "dtmc"; |
|
|
|
break; |
|
|
|
return "dtmc"; |
|
|
|
case ModelType::CTMC: |
|
|
|
stream << "ctmc"; |
|
|
|
break; |
|
|
|
return "ctmc"; |
|
|
|
case ModelType::MDP: |
|
|
|
stream << "mdp"; |
|
|
|
break; |
|
|
|
return "mdp"; |
|
|
|
case ModelType::CTMDP: |
|
|
|
stream << "ctmdp"; |
|
|
|
break; |
|
|
|
return "ctmdp"; |
|
|
|
case ModelType::MA: |
|
|
|
stream << "ma"; |
|
|
|
break; |
|
|
|
return "ma"; |
|
|
|
case ModelType::TA: |
|
|
|
stream << "ta"; |
|
|
|
break; |
|
|
|
return "ta"; |
|
|
|
case ModelType::PTA: |
|
|
|
stream << "pta"; |
|
|
|
break; |
|
|
|
return "pta"; |
|
|
|
case ModelType::STA: |
|
|
|
stream << "sta"; |
|
|
|
break; |
|
|
|
return "sta"; |
|
|
|
case ModelType::HA: |
|
|
|
stream << "ha"; |
|
|
|
break; |
|
|
|
return "ha"; |
|
|
|
case ModelType::PHA: |
|
|
|
stream << "pha"; |
|
|
|
break; |
|
|
|
return "pha"; |
|
|
|
case ModelType::SHA: |
|
|
|
stream << "sha"; |
|
|
|
break; |
|
|
|
return "sha"; |
|
|
|
} |
|
|
|
return stream; |
|
|
|
} |
|
|
|
|
|
|
|
ModelType getModelType(std::string const& input) { |
|
|
|