00001 #pragma ident "$Id: NovatelData.hpp 2429 2010-05-20 15:30:18Z schatzm $"
00002
00003
00009 #ifndef GPSTK_NOVATEL_DATA_HPP
00010 #define GPSTK_NOVATEL_DATA_HPP
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053 #include <ostream>
00054 #include "Exception.hpp"
00055 #include "FFStream.hpp"
00056 #include "RinexNavData.hpp"
00057 #include "RinexObsData.hpp"
00058 #include "NovatelStream.hpp"
00059
00060 namespace gpstk
00061 {
00064
00070 class NovatelData : public FFData
00071 {
00072 public:
00074 enum RecType
00075 {
00076 Unknown=0,
00077
00078 RGEB,
00079 RGEC,
00080 POSB,
00081 REPB,
00082 RCSB,
00083
00084 RANGE,
00085 RANGECMP,
00086 RAWEPHEM
00087 };
00088
00090 static const std::string RecNames[];
00091
00093 NovatelData(void) : rectype(Unknown), datasize(0), headersize(0), gpsWeek(-1)
00094 {}
00095
00097 virtual ~NovatelData(void) {}
00098
00101 bool isValid(void) const;
00102
00104 virtual bool isHeader(void) const { return false; }
00105
00107 virtual bool isData(void) const { return true; }
00108
00111 bool isNav(void) const;
00112
00115 bool isObs(void) const;
00116
00119 bool isAux(void) const;
00120
00122 bool isOEM2(void) const;
00123
00125 bool isOEM4(void) const;
00126
00128 virtual void dump(std::ostream& str) const;
00129
00132 void setWeek(long& gpsweek) { gpsWeek = gpsweek; }
00133
00136 operator RinexNavData() throw(gpstk::Exception);
00137
00140 operator RinexObsData() throw(gpstk::Exception);
00141
00143 RecType rectype;
00144 int recnum;
00145 long datasize;
00146 int headersize;
00147
00148 protected:
00150 virtual void reallyPutRecord(FFStream& s) const
00151 throw(std::exception, gpstk::StringUtils::StringException,
00152 gpstk::FFStreamError);
00153
00162 virtual void reallyGetRecord(FFStream& s)
00163 throw(std::exception, gpstk::StringUtils::StringException,
00164 gpstk::FFStreamError);
00165
00166 private:
00169 unsigned char buffer[65564];
00170
00177 long gpsWeek;
00178
00179 };
00180
00182
00183 }
00184
00185 #endif