| 205 | |
| 206 | |
| 207 | fmi2Status fmi2Terminate(fmi2Component c) |
| 208 | { |
| 209 | const auto component = static_cast<Fmi2Component*>(c); |
| 210 | try { |
| 211 | component->slave->Terminate(); |
| 212 | return fmi2OK; |
| 213 | } catch (const pythonfmu::fatal_error& e) { |
| 214 | component->logger->log(fmi2Fatal, e.what()); |
| 215 | return fmi2Fatal; |
| 216 | } catch (const std::exception& e) { |
| 217 | component->logger->log(fmi2Error, e.what()); |
| 218 | return fmi2Error; |
| 219 | } |
| 220 | } |
| 221 | |
| 222 | |
| 223 | fmi2Status fmi2Reset(fmi2Component c) |