ITK  4.6.0
Insight Segmentation and Registration Toolkit
itkDCMTKSeriesFileNames.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef __itkDCMTKSeriesFileNames_h
19 #define __itkDCMTKSeriesFileNames_h
20 #include "ITKIODCMTKExport.h"
21 
22 #include "itkProcessObject.h"
23 #include "itkObjectFactory.h"
24 #include "itkMacro.h"
25 #include <vector>
26 
27 namespace itk
28 {
51 class ITKIODCMTK_EXPORT DCMTKSeriesFileNames:public ProcessObject
52 {
53 public:
58 
59  typedef std::vector< std::string > FilenamesContainer;
60  typedef std::vector< std::string > SeriesUIDContainer;
61 
63  itkNewMacro(Self);
64 
66  itkTypeMacro(DCMTKSeriesFileNames, ProcessObject);
67 
68  /* -------- Define the API for DCMTKSeriesFileNames ----------- */
69 
71  void SetInputDirectory(const char *name);
72 
74  void SetInputDirectory(std::string const & name);
75 
77  void SetDirectory(std::string const & name)
78  {
79  SetInputDirectory(name);
80  }
81 
85  const FilenamesContainer & GetInputFileNames();
86 
88  void SetOutputDirectory(std::string const & name)
89  {
90  m_OutputDirectory = name;
91  this->Modified();
92  }
94 
100  const FilenamesContainer & GetOutputFileNames();
101 
108  const FilenamesContainer & GetFileNames(const std::string serie);
109 
115  const SeriesUIDContainer & GetSeriesUIDs();
116 
118  itkSetMacro(Recursive, bool);
119  itkGetConstMacro(Recursive, bool);
120  itkBooleanMacro(Recursive);
122 
127  void SetUseSeriesDetails(bool useSeriesDetails);
128 
134  {
135  return m_UseSeriesDetails;
136  }
137 
144  void AddSeriesRestriction(const std::string & /* tag */)
145  {
146  // m_SerieHelper->AddRestriction(tag);
147  }
148 
153  itkSetMacro(LoadSequences, bool);
154  itkGetConstMacro(LoadSequences, bool);
155  itkBooleanMacro(LoadSequences);
157 
162  itkSetMacro(LoadPrivateTags, bool);
163  itkGetConstMacro(LoadPrivateTags, bool);
164  itkBooleanMacro(LoadPrivateTags);
165 protected:
168  void PrintSelf(std::ostream & os, Indent indent) const;
170 
171 private:
172  DCMTKSeriesFileNames(const Self &); //purposely not implemented
173  void operator=(const Self &); //purposely not implemented
174 
176  void GetDicomData(const std::string &series, bool saveFileNames);
177 
179  std::string m_InputDirectory;
180 
182  std::string m_OutputDirectory;
183 
187 
192 
197 };
198 } //namespace ITK
199 
200 #endif // __itkDCMTKSeriesFileNames_h
std::vector< std::string > FilenamesContainer
Light weight base class for most itk classes.
Generate a sequence of filenames from a DICOM series.
void SetDirectory(std::string const &name)
The base class for all process objects (source, filters, mappers) in the Insight data processing pipe...
std::vector< std::string > SeriesUIDContainer
std::vector< std::string > FilenamesContainer
void SetOutputDirectory(std::string const &name)
Control indentation during Print() invocation.
Definition: itkIndent.h:49
void AddSeriesRestriction(const std::string &)