Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
mitkDICOMNullFileReader.cpp
Go to the documentation of this file.
1 /*===================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center,
6 Division of Medical and Biological Informatics.
7 All rights reserved.
8 
9 This software is distributed WITHOUT ANY WARRANTY; without
10 even the implied warranty of MERCHANTABILITY or FITNESS FOR
11 A PARTICULAR PURPOSE.
12 
13 See LICENSE.txt or http://www.mitk.org for details.
14 
15 ===================================================================*/
16 
18 
22 {
23 }
24 
27 {
28 }
29 
32 :DICOMFileReader(other)
33 {
34 }
35 
39 {
40  if (this != &other)
41  {
43  }
44  return *this;
45 }
46 
47 bool
49 ::operator==(const DICOMFileReader& other) const
50 {
51  return dynamic_cast<const Self*>(&other) != nullptr; // same class, we don't have members
52 }
53 void
55 ::InternalPrintConfiguration(std::ostream& os) const
56 {
57  os << "Nothing to configure" << std::endl;
58 }
59 
60 
61 void
64 {
65  this->ClearOutputs();
66 
67  StringList inputFilenames = this->GetInputFiles();
68  this->SetNumberOfOutputs( inputFilenames.size() );
69 
70  //generates one output for each input
71  unsigned int o = 0;
72  for (StringList::const_iterator inputIter = inputFilenames.begin();
73  inputIter != inputFilenames.end();
74  ++o, ++inputIter)
75  {
77  DICOMImageFrameList outputFrames;
78  outputFrames.push_back( DICOMImageFrameInfo::New(*inputIter) );
79 
80  block.SetImageFrameList( outputFrames );
81 
82  this->SetOutput( o, block );
83  }
84 }
85 
86 // void AllocateOutputImages();
87 
88 bool
91 {
92  // does nothing
93  return true;
94 }
95 
96 bool
98 ::CanHandleFile(const std::string& itkNotUsed(filename))
99 {
100  return true; // can handle all
101 }
void InternalPrintConfiguration(std::ostream &os) const override
Configuration description for human reader, to be implemented by sub-classes.
virtual bool CanHandleFile(const std::string &filename) override
Indicate whether this reader can handle given file.
virtual bool LoadImages() override
void SetImageFrameList(const DICOMImageFrameList &framelist)
List of frames that constitute the mitk::Image (DICOMImageFrames)
static const std::string filename
std::vector< DICOMImageFrameInfo::Pointer > DICOMImageFrameList
Output descriptor for DICOMFileReader.
virtual void AnalyzeInputFiles() override
Analyze input files.
std::vector< std::string > StringList
bool operator==(const DICOMFileReader &other) const override
DICOMFileReader & operator=(const DICOMFileReader &other)
Interface for DICOM readers that produce mitk::Images.
DICOMNullFileReader & operator=(const DICOMNullFileReader &other)
static itkEventMacro(BoundingShapeInteractionEvent, itk::AnyEvent) class MITKBOUNDINGSHAPE_EXPORT BoundingShapeInteractor Pointer New()
Basic interaction methods for mitk::GeometryData.