Mercurial > hg > orthanc-stone
comparison Framework/Deprecated/Volumes/StructureSetLoader.cpp @ 1222:21c2b0eee53c broker
deprecating MessageHandler
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Sat, 07 Dec 2019 18:18:07 +0100 |
parents | b537002f83a9 |
children | 0ca50d275b9a |
comparison
equal
deleted
inserted
replaced
1218:6f3f1ef347a3 | 1222:21c2b0eee53c |
---|---|
55 | 55 |
56 for (std::set<std::string>::const_iterator it = instances.begin(); | 56 for (std::set<std::string>::const_iterator it = instances.begin(); |
57 it != instances.end(); ++it) | 57 it != instances.end(); ++it) |
58 { | 58 { |
59 orthanc_.PostBinaryAsyncExpectJson("/tools/lookup", *it, | 59 orthanc_.PostBinaryAsyncExpectJson("/tools/lookup", *it, |
60 new OrthancStone::Callable<StructureSetLoader, OrthancApiClient::JsonResponseReadyMessage>(GetSharedObserver(), &StructureSetLoader::OnLookupCompleted)); | 60 new DeprecatedCallable<StructureSetLoader, OrthancApiClient::JsonResponseReadyMessage>(GetSharedObserver(), &StructureSetLoader::OnLookupCompleted)); |
61 } | 61 } |
62 | 62 |
63 BroadcastMessage(GeometryReadyMessage(*this)); | 63 BroadcastMessage(GeometryReadyMessage(*this)); |
64 } | 64 } |
65 | 65 |
79 throw Orthanc::OrthancException(Orthanc::ErrorCode_NetworkProtocol); | 79 throw Orthanc::OrthancException(Orthanc::ErrorCode_NetworkProtocol); |
80 } | 80 } |
81 | 81 |
82 const std::string& instance = lookup[0]["ID"].asString(); | 82 const std::string& instance = lookup[0]["ID"].asString(); |
83 orthanc_.GetJsonAsync("/instances/" + instance + "/tags", | 83 orthanc_.GetJsonAsync("/instances/" + instance + "/tags", |
84 new OrthancStone::Callable<StructureSetLoader, OrthancApiClient::JsonResponseReadyMessage>(GetSharedObserver(), &StructureSetLoader::OnReferencedSliceLoaded)); | 84 new DeprecatedCallable<StructureSetLoader, OrthancApiClient::JsonResponseReadyMessage>(GetSharedObserver(), &StructureSetLoader::OnReferencedSliceLoaded)); |
85 } | 85 } |
86 | 86 |
87 | 87 |
88 void StructureSetLoader::ScheduleLoadInstance(const std::string& instance) | 88 void StructureSetLoader::ScheduleLoadInstance(const std::string& instance) |
89 { | 89 { |
92 throw Orthanc::OrthancException(Orthanc::ErrorCode_BadSequenceOfCalls); | 92 throw Orthanc::OrthancException(Orthanc::ErrorCode_BadSequenceOfCalls); |
93 } | 93 } |
94 else | 94 else |
95 { | 95 { |
96 orthanc_.GetJsonAsync("/instances/" + instance + "/tags?ignore-length=3006-0050", | 96 orthanc_.GetJsonAsync("/instances/" + instance + "/tags?ignore-length=3006-0050", |
97 new OrthancStone::Callable<StructureSetLoader, OrthancApiClient::JsonResponseReadyMessage>(GetSharedObserver(), &StructureSetLoader::OnStructureSetLoaded)); | 97 new DeprecatedCallable<StructureSetLoader, OrthancApiClient::JsonResponseReadyMessage>(GetSharedObserver(), &StructureSetLoader::OnStructureSetLoaded)); |
98 } | 98 } |
99 } | 99 } |
100 | 100 |
101 | 101 |
102 OrthancStone::DicomStructureSet& StructureSetLoader::GetStructureSet() | 102 OrthancStone::DicomStructureSet& StructureSetLoader::GetStructureSet() |