MCPcopy Create free account
hub / github.com/MITK/MITK / GetBoundaryString

Function GetBoundaryString

Modules/Segmentation/src/Interactions/mitkMonaiLabelTool.cpp:256–265  ·  view source on GitHub ↗

* @brief Returns boundary string from Httplib response. */

Source from the content-addressed store, hash-verified

254 * @brief Returns boundary string from Httplib response.
255 */
256 std::string GetBoundaryString(const httplib::Result &response)
257 {
258 httplib::Headers headers = response->headers;
259 std::string contentType = headers.find("content-type")->second;
260 std::string delimiter = "boundary=";
261 std::string boundaryString =
262 contentType.substr(contentType.find(delimiter) + delimiter.length(), std::string::npos);
263 boundaryString.insert(0, "--");
264 return boundaryString;
265 }
266
267 /**
268 * @brief Returns image data string from monai label overall response.

Callers 1

PostInferRequestMethod · 0.85

Calls 1

findMethod · 0.45

Tested by

no test coverage detected