casa
$Rev:20696$
|
00001 //# OldGBTPositionTable.h: GBT Position FITS files are special 00002 //# Copyright (C) 1995,1997,1999 00003 //# Associated Universities, Inc. Washington DC, USA. 00004 //# 00005 //# This library is free software; you can redistribute it and/or modify it 00006 //# under the terms of the GNU Library General Public License as published by 00007 //# the Free Software Foundation; either version 2 of the License, or (at your 00008 //# option) any later version. 00009 //# 00010 //# This library is distributed in the hope that it will be useful, but WITHOUT 00011 //# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 00012 //# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public 00013 //# License for more details. 00014 //# 00015 //# You should have received a copy of the GNU Library General Public License 00016 //# along with this library; if not, write to the Free Software Foundation, 00017 //# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA. 00018 //# 00019 //# Correspondence concerning AIPS++ should be addressed as follows: 00020 //# Internet email: aips2-request@nrao.edu. 00021 //# Postal address: AIPS++ Project Office 00022 //# National Radio Astronomy Observatory 00023 //# 520 Edgemont Road 00024 //# Charlottesville, VA 22903-2475 USA 00025 //# 00026 //# 00027 //# $Id$ 00028 00029 #ifndef NRAO_OLDGBTPOSITIONTABLE_H 00030 #define NRAO_OLDGBTPOSITIONTABLE_H 00031 00032 #include <casa/aips.h> 00033 #include <fits/FITS/FITSTable.h> 00034 #include <casa/Containers/RecordField.h> 00035 00036 #include <casa/namespace.h> 00037 // <summary> 00038 // Attach a FITSTabular to a binary or ASCII table 00039 // </summary> 00040 // 00041 // <use visibility=export> 00042 // 00043 // <reviewed reviewer="" date="yyyy/mm/dd" tests="" demos=""> 00044 // </reviewed> 00045 // 00046 // <prerequisite> 00047 // <li> General knowledge of FITS binary and ASCII tables. 00048 // </prerequisite> 00049 // 00050 // <etymology> 00051 // </etymology> 00052 // 00053 // <synopsis> 00054 // FITSDtable is a FITSTabular which is attached to a FITS table (on disk only 00055 // presently), either Binary or ASCII. 00056 // </synopsis> 00057 // 00058 // <example> 00059 // </example> 00060 // 00061 // <motivation> 00062 // </motivation> 00063 // 00064 // <todo asof="1995/06/01"> 00065 // <li> 00066 // </todo> 00067 00068 class OldGBTPositionTable : public FITSTabular 00069 { 00070 public: 00071 // 0-relative HDU. It can never be zero by the FITS rules. 00072 OldGBTPositionTable(const String &fileName); 00073 ~OldGBTPositionTable(); 00074 00075 // Attach this FITSDtable to a new file name, same HDU# as at open time 00076 Bool reopen(const String &fileName); 00077 virtual const String &name() const { return name_p;} 00078 00079 virtual Bool isValid() const; 00080 00081 virtual const TableRecord &keywords() const; 00082 virtual const RecordDesc &description() const; 00083 virtual const Record &units() const; 00084 virtual const Record &displayFormats() const; 00085 virtual const Record &nulls() const; 00086 00087 virtual Bool pastEnd() const; 00088 virtual void next(); 00089 virtual const Record ¤tRow() const; 00090 private: 00091 // Undefined and inaccessible. An alternative would be to use reference 00092 // semantics like Table. 00093 OldGBTPositionTable(); 00094 OldGBTPositionTable(const OldGBTPositionTable &); 00095 OldGBTPositionTable &operator=(const OldGBTPositionTable &); 00096 00097 void fill_row(); 00098 void clear_self(); 00099 00100 Bool isValid_p; 00101 00102 String name_p; 00103 00104 uInt maxCount_p; 00105 uInt count_p; 00106 Double delta_time_p; 00107 RecordFieldPtr<Double> dmjdField_p; 00108 00109 Int row_nr_p; 00110 BinaryTableExtension *raw_table_p; 00111 FitsInput *io_p; 00112 TableRecord keywords_p; 00113 RecordDesc description_p; 00114 Record units_p; 00115 Record disps_p; 00116 Record nulls_p; 00117 Record row_p; 00118 // One per field in row_p, of the right type. i.e. casting required. 00119 Block<void *> row_fields_p; 00120 }; 00121 00122 00123 #endif