creaImageIOAbstractImageReader.h

Go to the documentation of this file.
00001 #ifndef __creaImageIOAbstractImageReader_h_INCLUDED__
00002 #define __creaImageIOAbstractImageReader_h_INCLUDED__
00003 
00004 
00005 #include <vtkImageData.h>
00006 #include <string>
00007 #include <map>
00008 #include <vector>
00009 #include <creaImageIOTreeAttributeMapType.h>
00010 
00011 namespace creaImageIO
00012 {
00013 
00014 
00019   //=====================================================================
00021   class AbstractImageReader 
00022   {
00023   public:
00024     AbstractImageReader() {}
00025     virtual ~AbstractImageReader() {}
00026 
00027     const std::string& GetName() const { return mName; }
00028     virtual void PushBackExtensions(std::vector<std::string>&) {}
00029     virtual bool CanRead(const std::string& filename) { return false; }
00030     virtual vtkImageData* ReadImage(const std::string& filename) { return 0; }
00031     virtual void ReadAttributes(const std::string& filename, 
00032                                 tree::AttributeMapType& attr) {}
00033 
00034   protected:
00035     void SetName(const std::string& s) { mName = s; }
00036   private:
00037     std::string mName;
00038   };
00039   //=====================================================================
00040 
00041 
00042 
00043 } // namespace creaImageIO
00044 
00045 
00046 
00047 #endif // #ifndef __creaImageIOAbstractImageReader_h_INCLUDED__

Generated on Mon Jun 22 10:49:30 2009 for CreaImageIO by  doxygen 1.5.3