comparison OrthancServer/OrthancRestApi/OrthancRestResources.cpp @ 1702:9980875edc7c db-changes

started work on SliceOrdering
author Sebastien Jodogne <s.jodogne@gmail.com>
date Mon, 12 Oct 2015 17:49:23 +0200
parents 4aaaecae5803
children b80e76dd1d56
comparison
equal deleted inserted replaced
1701:4aaaecae5803 1702:9980875edc7c
37 #include "../ServerToolbox.h" 37 #include "../ServerToolbox.h"
38 #include "../FromDcmtkBridge.h" 38 #include "../FromDcmtkBridge.h"
39 #include "../ResourceFinder.h" 39 #include "../ResourceFinder.h"
40 #include "../DicomFindQuery.h" 40 #include "../DicomFindQuery.h"
41 #include "../ServerContext.h" 41 #include "../ServerContext.h"
42 #include "../SliceOrdering.h"
42 43
43 44
44 namespace Orthanc 45 namespace Orthanc
45 { 46 {
46 // List all the patients, studies, series or instances ---------------------- 47 // List all the patients, studies, series or instances ----------------------
1091 return; 1092 return;
1092 } 1093 }
1093 } 1094 }
1094 1095
1095 1096
1097 static void OrderSlices(RestApiGetCall& call)
1098 {
1099 const std::string id = call.GetUriComponent("id", "");
1100
1101 ServerIndex& index = OrthancRestApi::GetIndex(call);
1102 SliceOrdering ordering(index, id);
1103
1104 }
1105
1106
1096 void OrthancRestApi::RegisterResources() 1107 void OrthancRestApi::RegisterResources()
1097 { 1108 {
1098 Register("/instances", ListResources<ResourceType_Instance>); 1109 Register("/instances", ListResources<ResourceType_Instance>);
1099 Register("/patients", ListResources<ResourceType_Patient>); 1110 Register("/patients", ListResources<ResourceType_Patient>);
1100 Register("/series", ListResources<ResourceType_Series>); 1111 Register("/series", ListResources<ResourceType_Series>);
1185 Register("/patients/{id}/instances-tags", GetChildInstancesTags); 1196 Register("/patients/{id}/instances-tags", GetChildInstancesTags);
1186 Register("/studies/{id}/instances-tags", GetChildInstancesTags); 1197 Register("/studies/{id}/instances-tags", GetChildInstancesTags);
1187 Register("/series/{id}/instances-tags", GetChildInstancesTags); 1198 Register("/series/{id}/instances-tags", GetChildInstancesTags);
1188 1199
1189 Register("/instances/{id}/content/*", GetRawContent); 1200 Register("/instances/{id}/content/*", GetRawContent);
1201
1202 Register("/series/{id}/ordered-slices", OrderSlices);
1190 } 1203 }
1191 } 1204 }