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

Method CleanupTempDirectory

Modules/RESTAPI/src/mitkRestServer.cpp:1244–1265  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1242}
1243
1244void RestServer::CleanupTempDirectory(const std::string& tempDir)
1245{
1246 if (tempDir.empty())
1247 {
1248 return;
1249 }
1250
1251 try
1252 {
1253 fs::path tempPath(tempDir);
1254 if (fs::exists(tempPath))
1255 {
1256 // Remove all contents recursively
1257 fs::remove_all(tempPath);
1258 MITK_DEBUG << "Cleaned up REST API temp directory: " << tempDir;
1259 }
1260 }
1261 catch (const std::exception& e)
1262 {
1263 MITK_WARN << "Failed to cleanup temp directory: " << e.what();
1264 }
1265}
1266
1267}

Callers 2

StartMethod · 0.95
StopMethod · 0.95

Calls 2

whatMethod · 0.80
emptyMethod · 0.45

Tested by

no test coverage detected