fw4spl
SSeriesDBLazyReader.hpp
1 /* ***** BEGIN LICENSE BLOCK *****
2  * FW4SPL - Copyright (C) IRCAD, 2009-2018.
3  * Distributed under the terms of the GNU Lesser General Public License (LGPL) as
4  * published by the Free Software Foundation.
5  * ****** END LICENSE BLOCK ****** */
6 
7 #pragma once
8 
9 #include "ioVtkGdcm/config.hpp"
10 
11 #include <fwIO/IReader.hpp>
12 
13 #include <boost/filesystem/path.hpp>
14 
15 #include <string>
16 
17 namespace fwMedData
18 {
19 class SeriesDB;
20 class Patient;
21 }
22 
23 namespace fwJobs
24 {
25 class IJob;
26 }
27 
28 namespace ioVtkGdcm
29 {
30 
55 class IOVTKGDCM_CLASS_API SSeriesDBLazyReader : public ::fwIO::IReader
56 {
57 
58 public:
59  typedef ::fwCom::Signal< void ( SPTR(::fwJobs::IJob) ) > JobCreatedSignalType;
60  typedef std::string ExtensionType;
61  typedef std::vector< ExtensionType > ExtensionsType;
62 
64 
66  IOVTKGDCM_API SSeriesDBLazyReader() noexcept;
67 
69  IOVTKGDCM_API virtual ~SSeriesDBLazyReader() noexcept;
70 
71 protected:
72 
74  IOVTKGDCM_API virtual void starting() override;
75 
77  IOVTKGDCM_API virtual void stopping() override;
78 
80  IOVTKGDCM_API virtual void configuring() override;
81 
83  IOVTKGDCM_API void updating() override;
84 
86  IOVTKGDCM_API void info(std::ostream& _sstream ) override;
87 
89  IOVTKGDCM_API virtual ExtensionsType getSupportedExtensions() override;
90 
92  IOVTKGDCM_API virtual std::string getSelectorDialogTitle() override;
93 
95  IOVTKGDCM_API virtual void configureWithIHM() override;
96 
98  IOVTKGDCM_API ::fwIO::IOPathType getIOPathType() const override;
99 
100 private:
101 
103  void notificationOfDBUpdate();
104 
106  SPTR(::fwMedData::SeriesDB) createSeriesDB(const ::boost::filesystem::path& dicomDir);
107 
108  SPTR(JobCreatedSignalType) m_sigJobCreated;
109 
110 };
111 
112 } // namespace ioVtkGdcm
#define SPTR(_cls_)
This class contains helper to generate Medical Data (SeriesDB, ImageSeries, ...). ...
Namespace containing medical data.
STL namespace.
Reader service API. It manages extension points definition and extension configuration.
Definition: IReader.hpp:34
ioVtkGdcm contains services to read and write Series using vtk and gdcm libraries.
#define fwCoreServiceClassDefinitionsMacro(_classinfo_)
Generate common code for services classes.
The namespace fwIO contains the base interface for reader and writer services.
Definition: ioTypes.hpp:16
This namespace fwJobs provides jobs management.
This service reads a dicom dir in lazy mode, and provides a fwMedData::SeriesDB.