9 #include "fwGdcmIO/config.hpp" 10 #include "fwGdcmIO/container/DicomInstance.hpp" 12 #include <fwData/Object.hpp> 14 #include <fwLog/Logger.hpp> 16 #include <gdcmReader.h> 35 template<
class DATATYPE >
41 typedef std::function< void (std::uint64_t) > ProgressCallback;
42 typedef std::function< bool () > CancelRequestedCallback;
55 const SPTR(::gdcm::Reader)& reader,
57 const SPTR(DATATYPE)&
object,
58 const ::fwLog::Logger::sptr& logger =
nullptr,
59 const ProgressCallback progress =
nullptr,
60 CancelRequestedCallback cancel =
nullptr);
63 FWGDCMIO_API
virtual ~InformationEntity();
71 SPTR(::gdcm::Reader) m_reader;
83 ProgressCallback m_progressCallback;
86 CancelRequestedCallback m_cancelRequestedCallback;
91 template< class DATATYPE >
92 InformationEntity<DATATYPE>::InformationEntity(const
CSPTR(::
fwMedData::DicomSeries)& dicomSeries,
93 const
SPTR(::gdcm::Reader)& reader,
94 const
SPTR(::
fwGdcmIO::container::DicomInstance)& instance,
95 const
SPTR(DATATYPE)&
object,
96 const ::
fwLog::Logger::sptr& logger,
97 ProgressCallback progress,
98 CancelRequestedCallback cancel) :
99 m_dicomSeries(dicomSeries),
101 m_instance(instance),
104 m_progressCallback(progress),
105 m_cancelRequestedCallback(cancel)
107 SLM_ASSERT(
"DicomSeries should not be null.", dicomSeries);
108 SLM_ASSERT(
"Reader should not be null.", reader);
109 SLM_ASSERT(
"Instance should not be null.", instance);
110 SLM_ASSERT(
"Object should not be null.",
object);
111 SLM_ASSERT(
"Logger should not be null.", logger);
116 template<
class DATATYPE >
Namespace containing medical data.
This class defines a DICOM SOP instance. It is useful during the whole writing process. This class allows to share data between module writers.
The namespace fwGdcmIO contains reader, writer and helper for dicom data.
fwLog contains classes used to manage logs.
#define SLM_ASSERT(message, cond)
work like 'assert' from 'cassert', with in addition a message logged by spylog (with FATAL loglevel) ...