X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=src%2Fgdcm.h;h=aea4edc5c3a450ef9a9d4570a0b5af1ee7b45e92;hb=953fdb8435f0957ba61cf9f0154ed0dc67d53981;hp=9d159fb9bd96df58b8ac78ecdeeaa195c923e195;hpb=551b84c1dc82294c4fc7356da0b5b1b3d74f7645;p=gdcm.git diff --git a/src/gdcm.h b/src/gdcm.h index 9d159fb9..aea4edc5 100644 --- a/src/gdcm.h +++ b/src/gdcm.h @@ -17,16 +17,19 @@ // problems appears at loading of _gdcm.[so/dll]). So, simply uncomment // the declaration once you provided the definition of the method... +#ifndef GDCM_H +#define GDCM_H + #include -#ifdef _MSC_VER -using namespace std; // string type lives in the std namespace on VC++ -#endif +using namespace std; #include #include // For size_t #include // FIXME For FILE on GCC only #include #include +#include "gdcmException.h" + // The requirement for the hash table (or map) that // we shall use: @@ -368,8 +371,10 @@ protected: int anonymize(ostream&); // FIXME : anonymize should be a friend ? public: void LoadElements(void); - virtual void ParseHeader(void); - gdcmHeader(const char* filename); + virtual void ParseHeader(bool exception_on_error = false) + throw(gdcmFormatError); + gdcmHeader(const char *filename, bool exception_on_error = false) + throw(gdcmFileError); virtual ~gdcmHeader(); size_t GetPixelOffset(void); @@ -544,3 +549,4 @@ public: //class gdcmMultiFrame : gdcmFile; +#endif // #ifndef GDCM_H