Mercurial > hg > orthanc
comparison OrthancFramework/Sources/Toolbox.cpp @ 4297:785a2713323e
abi continued
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Thu, 05 Nov 2020 17:20:49 +0100 |
parents | a38376b80cd1 |
children | 3af1d763763a |
comparison
equal
deleted
inserted
replaced
4296:3b70a2e6a06c | 4297:785a2713323e |
---|---|
2117 const char c = hex[i]; | 2117 const char c = hex[i]; |
2118 if (!((c >= 'A' && c <= 'F') || | 2118 if (!((c >= 'A' && c <= 'F') || |
2119 (c >= 'a' && c <= 'f') || | 2119 (c >= 'a' && c <= 'f') || |
2120 (c >= '0' && c <= '9'))) | 2120 (c >= '0' && c <= '9'))) |
2121 { | 2121 { |
2122 throw Orthanc::OrthancException(Orthanc::ErrorCode_ParameterOutOfRange, | 2122 throw OrthancException(ErrorCode_ParameterOutOfRange, |
2123 "Not an hexadecimal number"); | 2123 "Not an hexadecimal number"); |
2124 } | 2124 } |
2125 } | 2125 } |
2126 | 2126 |
2127 std::vector<uint8_t> decimal; | 2127 std::vector<uint8_t> decimal; |
2128 decimal.push_back(0); | 2128 decimal.push_back(0); |
2211 const Json::Value& source, | 2211 const Json::Value& source, |
2212 DicomToJsonFormat format) | 2212 DicomToJsonFormat format) |
2213 { | 2213 { |
2214 if (!source.isObject()) | 2214 if (!source.isObject()) |
2215 { | 2215 { |
2216 throw Orthanc::OrthancException(Orthanc::ErrorCode_BadFileFormat); | 2216 throw OrthancException(ErrorCode_BadFileFormat); |
2217 } | 2217 } |
2218 | 2218 |
2219 target = Json::objectValue; | 2219 target = Json::objectValue; |
2220 Json::Value::Members members = source.getMemberNames(); | 2220 Json::Value::Members members = source.getMemberNames(); |
2221 | 2221 |