FrameType.hxx

Go to the documentation of this file.
00001 
00002 
00003 
00004 //-----------------------------------------------------------------------------
00005 // CVS: $Revision: 4785 $, $Date: 2008-05-20 14:19:36 +0100 (Tue, 20 May 2008) $, $Author: RossCollins $
00006 //-----------------------------------------------------------------------------
00007 #ifndef FRAMETYPE_H
00008 #define FRAMETYPE_H
00009 
00010 #include "DataMethod.hxx"
00011 #include "DataOps.h"
00012 #include "FitsFile.h"
00013 //-----------------------------------------------------------------------------
00016 template<typename DataType>
00017 class FrameType : public DataMethod<DataType>
00018 {
00019 public:
00021     FrameType(const FitsFile& aFile)
00022     {
00023       DataMethod<DataType>::methodName = "FrameType";
00024       mFrameType = DataOps::getFrameType(aFile.getFileName());
00025     }
00026 
00028     virtual ~FrameType() { }
00029 
00031     void setSource(IntMap& tbls, IntMap& cols, StringMap units) { }
00032 
00034     void setTarget(IntMap& cols, StringMap units) { ftypeColno = cols[0]; }
00035 
00039     void doit(TableData<DataType>& data, int row1, int row2)
00040     {
00041       for (int rowNo = row1; rowNo < row2; ++rowNo)
00042       {
00043         data.assign(ftypeColno, rowNo, mFrameType);
00044       }
00045     }
00046 
00047   // No data from raw data included
00048   void doit2(TableData<DataType>& rawData, TableData<DataType>& data, int row1, int row2) { }
00049 
00050 private:
00051     int ftypeColno;
00052     std::string mFrameType;
00053 };
00054 //-----------------------------------------------------------------------------
00055 #endif
00056 //-----------------------------------------------------------------------------
00057 // Change log:
00058 //
00059 // 27-May-2004,  IAB: Original version.
00060 //  7-Apr-2008, ETWS: Upgraded to use new detection table layout.
Generated on Mon Oct 4 10:38:34 2010 for WfcamSrc by  doxygen 1.6.3