GDCM
2.2.3
|
00001 /*========================================================================= 00002 00003 Program: GDCM (Grassroots DICOM). A DICOM library 00004 00005 Copyright (c) 2006-2011 Mathieu Malaterre 00006 All rights reserved. 00007 See Copyright.txt or http://gdcm.sourceforge.net/Copyright.html for details. 00008 00009 This software is distributed WITHOUT ANY WARRANTY; without even 00010 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00011 PURPOSE. See the above copyright notice for more information. 00012 00013 =========================================================================*/ 00014 #ifndef GDCMFILEANONYMIZER_H 00015 #define GDCMFILEANONYMIZER_H 00016 00017 #include "gdcmSubject.h" 00018 #include "gdcmEvent.h" 00019 #include "gdcmTag.h" 00020 #include "gdcmVL.h" 00021 00022 namespace gdcm 00023 { 00024 class FileAnonymizerInternals; 00025 00042 class GDCM_EXPORT FileAnonymizer : public Subject 00043 { 00044 public: 00045 FileAnonymizer(); 00046 ~FileAnonymizer(); 00047 00050 void Empty( Tag const &t ); 00051 00053 void Remove( Tag const &t ); 00054 00058 void Replace( Tag const &t, const char *value ); 00059 00062 void Replace( Tag const &t, const char *value, VL const & vl ); 00063 00065 void SetInputFileName(const char *filename_native); 00066 00068 void SetOutputFileName(const char *filename_native); 00069 00071 bool Write(); 00072 00073 private: 00074 bool ComputeEmptyTagPosition(); 00075 bool ComputeRemoveTagPosition(); 00076 bool ComputeReplaceTagPosition(); 00077 FileAnonymizerInternals *Internals; 00078 00079 }; 00080 00081 } // end namespace gdcm 00082 00083 #endif //GDCMFILEANONYMIZER_H