comparison ViewerPlugin/DicomPyramidCache.h @ 196:b0bd22077cd8

sharing code with orthanc-stone
author Sebastien Jodogne <s.jodogne@gmail.com>
date Wed, 01 Jul 2020 17:57:38 +0200
parents f299c191cd76
children 1e864138f0da
comparison
equal deleted inserted replaced
195:fda17c92d784 196:b0bd22077cd8
32 class DicomPyramidCache : public boost::noncopyable 32 class DicomPyramidCache : public boost::noncopyable
33 { 33 {
34 private: 34 private:
35 typedef Orthanc::LeastRecentlyUsedIndex<std::string, DicomPyramid*> Cache; 35 typedef Orthanc::LeastRecentlyUsedIndex<std::string, DicomPyramid*> Cache;
36 36
37 boost::mutex mutex_; 37 boost::mutex mutex_;
38 OrthancPlugins::IOrthancConnection& orthanc_; 38 OrthancStone::IOrthancConnection& orthanc_;
39 size_t maxSize_; 39 size_t maxSize_;
40 Cache cache_; 40 Cache cache_;
41 41
42 42
43 DicomPyramid* GetCachedPyramid(const std::string& seriesId); 43 DicomPyramid* GetCachedPyramid(const std::string& seriesId);
44 44
45 DicomPyramid& GetPyramid(const std::string& seriesId, 45 DicomPyramid& GetPyramid(const std::string& seriesId,
46 boost::mutex::scoped_lock& lock); 46 boost::mutex::scoped_lock& lock);
47 47
48 public: 48 public:
49 DicomPyramidCache(OrthancPlugins::IOrthancConnection& orthanc, 49 DicomPyramidCache(OrthancStone::IOrthancConnection& orthanc,
50 size_t maxSize); 50 size_t maxSize);
51 51
52 ~DicomPyramidCache(); 52 ~DicomPyramidCache();
53 53
54 void Invalidate(const std::string& seriesId); 54 void Invalidate(const std::string& seriesId);