Mercurial > hg > orthanc
comparison OrthancServer/Sources/ResourceFinder.cpp @ 5617:8905ffa45fc2 find-refactoring
started listing of children resources
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Thu, 09 May 2024 14:59:17 +0200 |
parents | 1e92fb051fd7 |
children | 1864b16bc7b1 |
comparison
equal
deleted
inserted
replaced
5616:1e92fb051fd7 | 5617:8905ffa45fc2 |
---|---|
359 ResourceFinder::ResourceFinder(ResourceType level, | 359 ResourceFinder::ResourceFinder(ResourceType level, |
360 bool expand) : | 360 bool expand) : |
361 request_(level), | 361 request_(level), |
362 expand_(expand), | 362 expand_(expand), |
363 format_(DicomToJsonFormat_Human), | 363 format_(DicomToJsonFormat_Human), |
364 allowStorageAccess_(true), | |
364 hasRequestedTags_(false), | 365 hasRequestedTags_(false), |
365 includeAllMetadata_(false) | 366 includeAllMetadata_(false) |
366 { | 367 { |
367 if (expand) | 368 if (expand) |
368 { | 369 { |
501 InjectRequestedTags(requestedTags, missingTags, resource, ResourceType_Series, requestedSeriesTags_); | 502 InjectRequestedTags(requestedTags, missingTags, resource, ResourceType_Series, requestedSeriesTags_); |
502 InjectRequestedTags(requestedTags, missingTags, resource, ResourceType_Instance, requestedInstanceTags_); | 503 InjectRequestedTags(requestedTags, missingTags, resource, ResourceType_Instance, requestedInstanceTags_); |
503 | 504 |
504 if (!missingTags.empty()) | 505 if (!missingTags.empty()) |
505 { | 506 { |
507 if (!allowStorageAccess_) | |
508 { | |
509 throw OrthancException(ErrorCode_BadSequenceOfCalls, | |
510 "Cannot add missing requested tags, as access to file storage is disallowed"); | |
511 } | |
512 | |
506 OrthancConfiguration::ReaderLock lock; | 513 OrthancConfiguration::ReaderLock lock; |
507 if (lock.GetConfiguration().IsWarningEnabled(Warnings_001_TagsBeingReadFromStorage)) | 514 if (lock.GetConfiguration().IsWarningEnabled(Warnings_001_TagsBeingReadFromStorage)) |
508 { | 515 { |
509 std::string missings; | 516 std::string missings; |
510 FromDcmtkBridge::FormatListOfTags(missings, missingTags); | 517 FromDcmtkBridge::FormatListOfTags(missings, missingTags); |