Mercurial > hg > orthanc
comparison OrthancServer/ServerIndex.cpp @ 1728:4941494b5dd8 db-changes
rename LookupIdentifier as LookupIdentifierExact
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Tue, 20 Oct 2015 15:03:52 +0200 |
parents | 1ae29c5e52fb |
children | b3de74dec2d5 |
comparison
equal
deleted
inserted
replaced
1727:1ae29c5e52fb | 1728:4941494b5dd8 |
---|---|
1886 LogChange(id, ChangeType_NewChildInstance, type, publicId); | 1886 LogChange(id, ChangeType_NewChildInstance, type, publicId); |
1887 } | 1887 } |
1888 | 1888 |
1889 | 1889 |
1890 | 1890 |
1891 void ServerIndex::LookupIdentifier(std::list<std::string>& result, | 1891 void ServerIndex::LookupIdentifierExact(std::list<std::string>& result, |
1892 ResourceType level, | 1892 ResourceType level, |
1893 const DicomTag& tag, | 1893 const DicomTag& tag, |
1894 const std::string& value) | 1894 const std::string& value) |
1895 { | 1895 { |
1896 assert((level == ResourceType_Patient && tag == DICOM_TAG_PATIENT_ID) || | 1896 assert((level == ResourceType_Patient && tag == DICOM_TAG_PATIENT_ID) || |
1897 (level == ResourceType_Study && tag == DICOM_TAG_STUDY_INSTANCE_UID) || | 1897 (level == ResourceType_Study && tag == DICOM_TAG_STUDY_INSTANCE_UID) || |
1898 (level == ResourceType_Study && tag == DICOM_TAG_ACCESSION_NUMBER) || | 1898 (level == ResourceType_Study && tag == DICOM_TAG_ACCESSION_NUMBER) || |
1899 (level == ResourceType_Series && tag == DICOM_TAG_SERIES_INSTANCE_UID) || | 1899 (level == ResourceType_Series && tag == DICOM_TAG_SERIES_INSTANCE_UID) || |
1902 result.clear(); | 1902 result.clear(); |
1903 | 1903 |
1904 boost::mutex::scoped_lock lock(mutex_); | 1904 boost::mutex::scoped_lock lock(mutex_); |
1905 | 1905 |
1906 std::list<int64_t> id; | 1906 std::list<int64_t> id; |
1907 db_.LookupIdentifier(id, level, tag, value); | 1907 db_.LookupIdentifierExact(id, level, tag, value); |
1908 | 1908 |
1909 for (std::list<int64_t>::const_iterator | 1909 for (std::list<int64_t>::const_iterator |
1910 it = id.begin(); it != id.end(); ++it) | 1910 it = id.begin(); it != id.end(); ++it) |
1911 { | 1911 { |
1912 result.push_back(db_.GetPublicId(*it)); | 1912 result.push_back(db_.GetPublicId(*it)); |