]> Creatis software - clitk.git/blobdiff - common/clitkGateAsciiImageIO.h
GateAsciiImageIO is now cross-platform using itksys::RegularExpression
[clitk.git] / common / clitkGateAsciiImageIO.h
index b7fa18f53a2891368a0cb8b05589d2e193950987..ddcd00fbb1d9f28ff3c5108fe8b53174d3db380a 100644 (file)
@@ -19,7 +19,8 @@
 #define CLITKGATEASCIIIMAGEIO_H
 
 // itk include
-#include "itkImageIOBase.h"
+#include <itkImageIOBase.h>
+#include <itksys/RegularExpression.hxx>
 
 #if defined (_MSC_VER) && (_MSC_VER < 1600)
 //SR: taken from
@@ -63,13 +64,16 @@ namespace clitk {
            virtual void Read(void * buffer);
 
            /*-------- This part of the interfaces deals with writing data. ----- */
-           virtual void WriteImageInformation(bool keepOfStream) { ; }
-           virtual void WriteImageInformation() { WriteImageInformation(false); }
+           virtual void WriteImageInformation();
            virtual bool CanWriteFile(const char* filename);
            virtual void Write(const void* buffer);
 
+           virtual bool SupportsDimension(unsigned long dim);
+
        protected:
-           int m_HeaderSize;
+            static bool ReadHeader(FILE* handle, GateAsciiHeader& header);
+           static bool ReadLine(FILE* handle, std::string& line);
+            static bool FindRegularExpressionNextLine(itksys::RegularExpression &reg, std::string &s, FILE* handle);
 
     }; // end class GateAsciiImageIO
 } // end namespace