| 18 | static const std::string OUTPUT_TYPE_STRING_BECH32 = "bech32"; |
| 19 | |
| 20 | bool ParseOutputType(const std::string& type, OutputType& output_type) |
| 21 | { |
| 22 | if (type == OUTPUT_TYPE_STRING_LEGACY) { |
| 23 | output_type = OutputType::LEGACY; |
| 24 | return true; |
| 25 | } else if (type == OUTPUT_TYPE_STRING_P2SH_SEGWIT) { |
| 26 | output_type = OutputType::P2SH_SEGWIT; |
| 27 | return true; |
| 28 | } else if (type == OUTPUT_TYPE_STRING_BECH32) { |
| 29 | output_type = OutputType::BECH32; |
| 30 | return true; |
| 31 | } |
| 32 | return false; |
| 33 | } |
| 34 | |
| 35 | const std::string& FormatOutputType(OutputType type) |
| 36 | { |
no outgoing calls
no test coverage detected