Mercurial > hg > orthanc
comparison OrthancServer/DatabaseWrapper.h @ 1241:90d2f320862d
refactoring
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Fri, 05 Dec 2014 17:22:53 +0100 |
parents | 62c35e4b67db |
children | 58e6a89c3ef4 |
comparison
equal
deleted
inserted
replaced
1240:62c35e4b67db | 1241:90d2f320862d |
---|---|
94 ResourceType GetResourceType(int64_t resourceId); | 94 ResourceType GetResourceType(int64_t resourceId); |
95 | 95 |
96 void AttachChild(int64_t parent, | 96 void AttachChild(int64_t parent, |
97 int64_t child); | 97 int64_t child); |
98 | 98 |
99 void GetChildren(Json::Value& childrenPublicIds, | |
100 int64_t id); | |
101 | |
102 void DeleteResource(int64_t id); | 99 void DeleteResource(int64_t id); |
103 | 100 |
104 void SetMetadata(int64_t id, | 101 void SetMetadata(int64_t id, |
105 MetadataType type, | 102 MetadataType type, |
106 const std::string& value); | 103 const std::string& value); |
131 void SetMainDicomTags(int64_t id, | 128 void SetMainDicomTags(int64_t id, |
132 const DicomMap& tags); | 129 const DicomMap& tags); |
133 | 130 |
134 void GetMainDicomTags(DicomMap& map, | 131 void GetMainDicomTags(DicomMap& map, |
135 int64_t id); | 132 int64_t id); |
136 | |
137 bool GetParentPublicId(std::string& result, | |
138 int64_t id); | |
139 | 133 |
140 void GetChildrenPublicId(std::list<std::string>& result, | 134 void GetChildrenPublicId(std::list<std::string>& result, |
141 int64_t id); | 135 int64_t id); |
142 | 136 |
143 void GetChildrenInternalId(std::list<int64_t>& result, | 137 void GetChildrenInternalId(std::list<int64_t>& result, |
166 int64_t since, | 160 int64_t since, |
167 unsigned int maxResults); | 161 unsigned int maxResults); |
168 | 162 |
169 void GetLastExportedResource(Json::Value& target); | 163 void GetLastExportedResource(Json::Value& target); |
170 | 164 |
171 // For unit testing only! | |
172 int64_t GetTableRecordCount(const std::string& table); | |
173 | |
174 uint64_t GetTotalCompressedSize(); | 165 uint64_t GetTotalCompressedSize(); |
175 | 166 |
176 uint64_t GetTotalUncompressedSize(); | 167 uint64_t GetTotalUncompressedSize(); |
177 | 168 |
178 uint64_t GetResourceCount(ResourceType resourceType); | 169 uint64_t GetResourceCount(ResourceType resourceType); |
179 | 170 |
180 void GetAllPublicIds(Json::Value& target, | 171 void GetAllPublicIds(std::list<std::string>& target, |
181 ResourceType resourceType); | 172 ResourceType resourceType); |
182 | 173 |
183 bool SelectPatientToRecycle(int64_t& internalId); | 174 bool SelectPatientToRecycle(int64_t& internalId); |
184 | 175 |
185 bool SelectPatientToRecycle(int64_t& internalId, | 176 bool SelectPatientToRecycle(int64_t& internalId, |
221 void LookupIdentifier(std::list<int64_t>& result, | 212 void LookupIdentifier(std::list<int64_t>& result, |
222 const std::string& value); | 213 const std::string& value); |
223 | 214 |
224 void GetAllMetadata(std::map<MetadataType, std::string>& result, | 215 void GetAllMetadata(std::map<MetadataType, std::string>& result, |
225 int64_t id); | 216 int64_t id); |
217 | |
218 | |
219 | |
220 | |
221 /** | |
222 * The methods declared below are for unit testing only! | |
223 **/ | |
224 | |
225 void GetChildren(std::list<std::string>& childrenPublicIds, | |
226 int64_t id); | |
227 | |
228 int64_t GetTableRecordCount(const std::string& table); | |
229 | |
230 bool GetParentPublicId(std::string& result, | |
231 int64_t id); | |
232 | |
226 }; | 233 }; |
227 } | 234 } |