DSN6File.h

Go to the documentation of this file.
00001 // -*- Mode: C++; tab-width: 2; -*-
00002 // vi: set ts=2:
00003 //
00004 // $Id: DSN6File.h,v 1.1.4.1 2007/03/25 21:23:41 oliver Exp $
00005 //
00006 
00007 #ifndef BALL_FORMAT_DSN6FILE_H
00008 #define BALL_FORMAT_DSN6FILE_H
00009 
00010 #ifndef BALL_SYSTEM_FILE_H
00011 # include <BALL/SYSTEM/file.h>
00012 #endif
00013 
00014 #ifndef BALL_DATATYPE_REGULARDATA3D_H
00015 # include <BALL/DATATYPE/regularData3D.h>
00016 #endif
00017 
00018 namespace BALL
00019 {
00025   class BALL_EXPORT DSN6File
00026     : public File
00027   {
00028 
00029     public:
00030 
00031     BALL_CREATE(DSN6File)
00032 
00033     
00036 
00038     DSN6File()
00039       ;
00040 
00042     DSN6File(const DSN6File& file)
00043       throw(Exception::FileNotFound);
00044 
00046     DSN6File(const String& name, File::OpenMode open_mode = std::ios::in)
00047       ;
00048 
00050     virtual ~DSN6File()
00051       ;
00052 
00054 
00057 
00059     const DSN6File& operator = (const DSN6File& file)
00060       ;
00061 
00063     virtual void clear()
00064       ;
00065 
00067 
00070 
00072     bool operator == (const DSN6File& file) const
00073       ;
00074 
00076     bool isSwappingBytes() const
00077       ;
00078 
00080 
00081 
00082 
00085     virtual bool open(const String& name, File::OpenMode open_mode = std::ios::in)
00086       throw(Exception::FileNotFound);
00087 
00091     virtual bool readHeader()
00092       ;
00093 
00095     virtual bool read(RegularData3D& map)
00096       ;
00097 
00101     virtual bool writeHeader()
00102       ;
00103 
00105 
00108 
00110 
00111     protected:
00112 
00113       short int readHeaderValue_(char* header, Position pos)
00114         ;
00115 
00116       void convertBrick_(char* brick)
00117         ;
00118 
00120       bool swap_bytes_;
00121 
00123       Vector3 start_;
00124 
00126       Vector3 extent_;
00127 
00129       Vector3 sampling_rate_;
00130       
00132       Vector3 crystal_dimension_;
00133 
00135       Angle alpha_, beta_, gamma_;
00136 
00138       float cell_scaling_;
00139 
00141       float prod_;
00142       float plus_;
00143 
00145       Vector3 origin_, xaxis_, yaxis_, zaxis_;
00146   };
00147 } // namespace BALL
00148 
00149 #endif // BALL_FORMAT_DCDFILE_H