| 478 | |
| 479 | |
| 480 | ParameterMapStringFormat |
| 481 | Conversion::StringToParameterMapStringFormat(const std::string & str) |
| 482 | { |
| 483 | if (str.empty() || str == "txt") |
| 484 | { |
| 485 | return ParameterMapStringFormat::LegacyTxt; |
| 486 | } |
| 487 | if (str == "TOML") |
| 488 | { |
| 489 | return ParameterMapStringFormat::Toml; |
| 490 | } |
| 491 | itkGenericExceptionMacro("Failed to convert to the following string to ParameterMapStringFormat: \"" << str << '"'); |
| 492 | } |
| 493 | |
| 494 | std::string |
| 495 | Conversion::CreateParameterMapFileNameExtension(const ParameterMapStringFormat format) |