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
mitkCollectionWriter.h
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 
17 #ifndef MITK_COLLECTION_WRITER_H
18 #define MITK_COLLECTION_WRITER_H
19 
20 #include "mitkCommon.h"
21 #include "mitkDataCollection.h"
22 #include "mitkCollectionReader.h"
23 #include <MitkDataCollectionExports.h>
24 
25 namespace mitk {
26  class MITKDATACOLLECTION_EXPORT CollectionWriter
27  {
28  public:
29 
30  typedef float TensorScalar;
47  static bool ExportCollectionToFolder(DataCollection* dataCollection, std::string xmlFile , std::vector<std::string> filter);
48 
49  static bool ExportCollectionToFolder(DataCollection* dataCollection, std::string xmlFile);
50 
66  static bool SaveCollection(DataCollection* dataCollection, std::vector<std::string> filter, std::string xmlFile = "");
67 
68  static bool FolderToXml(std::string folder, std::string collectionType, std::string xmlFile, std::vector<std::string> filter, std::vector<std::string> seriesNames);
69 
70  // GTV last entry in filter list, this item will be made to TARGET
71  static bool SingleFolderToXml(std::string folder, std::string xmlFile, std::vector<std::string> filter, std::vector<std::string> seriesNames, bool longDate = true, int skipUntil = 0, float months = 0);
72 
73  protected:
74 
75  private:
76 
77  static size_t GetIndexForinXMonths(CollectionReader::FileListType fileList, float months, size_t curIndex, std::vector<std::string> filter);
78  };
79 } // namespace mitk
80 
81 #endif /* MITK_COLLECTION_WRITER_H */
DataCollection - Class to facilitate loading/accessing structured data.
std::vector< std::vector< std::string > > FileListType