comparison Plugins/Engine/OrthancPluginDatabase.cpp @ 3054:3638de45a08c db-changes

backward compatibility with filtering identifiers
author Sebastien Jodogne <s.jodogne@gmail.com>
date Fri, 21 Dec 2018 12:45:24 +0100
parents 3f986ce336c8
children 87f52703ebbc
comparison
equal deleted inserted replaced
3053:3f986ce336c8 3054:3638de45a08c
1123 1123
1124 1124
1125 void OrthancPluginDatabase::LookupIdentifier(std::list<int64_t>& result, 1125 void OrthancPluginDatabase::LookupIdentifier(std::list<int64_t>& result,
1126 ResourceType level, 1126 ResourceType level,
1127 const DicomTag& tag, 1127 const DicomTag& tag,
1128 IdentifierConstraintType type, 1128 Compatibility::IdentifierConstraintType type,
1129 const std::string& value) 1129 const std::string& value)
1130 { 1130 {
1131 if (extensions_.lookupIdentifier3 == NULL) 1131 if (extensions_.lookupIdentifier3 == NULL)
1132 { 1132 {
1133 throw OrthancException(ErrorCode_DatabasePlugin, 1133 throw OrthancException(ErrorCode_DatabasePlugin,
1154 { 1154 {
1155 if (extensions_.lookupIdentifierRange == NULL) 1155 if (extensions_.lookupIdentifierRange == NULL)
1156 { 1156 {
1157 // Default implementation, for plugins using Orthanc SDK <= 1.3.2 1157 // Default implementation, for plugins using Orthanc SDK <= 1.3.2
1158 1158
1159 LookupIdentifier(result, level, tag, IdentifierConstraintType_GreaterOrEqual, start); 1159 LookupIdentifier(result, level, tag, Compatibility::IdentifierConstraintType_GreaterOrEqual, start);
1160 1160
1161 std::list<int64_t> b; 1161 std::list<int64_t> b;
1162 LookupIdentifier(result, level, tag, IdentifierConstraintType_SmallerOrEqual, end); 1162 LookupIdentifier(result, level, tag, Compatibility::IdentifierConstraintType_SmallerOrEqual, end);
1163 1163
1164 result.splice(result.end(), b); 1164 result.splice(result.end(), b);
1165 } 1165 }
1166 else 1166 else
1167 { 1167 {