Changeset 3837 in ntrip for trunk/BNC/rinex/rnxobsfile.cpp


Ignore:
Timestamp:
Apr 12, 2012, 12:01:37 PM (12 years ago)
Author:
mervart
Message:
 
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/rinex/rnxobsfile.cpp

    r3722 r3837  
    169169      delete in;
    170170    }
     171    else if (key == "TIME OF FIRST OBS") {
     172      QTextStream in(value.toAscii(), QIODevice::ReadOnly);
     173      int year, month, day, hour, min;
     174      double sec;
     175      in >> year >> month >> day >> hour >> min >> sec;
     176      _startTime.set(year, month, day, hour, min, sec);
     177    }
    171178    if (maxLines > 0 && numLines == maxLines) {
    172179      break;
     
    248255      ttPrev = rnxEpo->tt;
    249256    }
     257    _stream->seek(0);
     258    _header.read(_stream);
     259  }
     260
     261  // Time of first observation
     262  // -------------------------
     263  if (!_header._startTime.valid()) {
     264    const t_rnxEpo* rnxEpo = nextEpoch();
     265    if (!rnxEpo) {
     266      throw QString("t_rnxObsFile: not enough epochs");
     267    }
     268    _header._startTime = rnxEpo->tt;
    250269    _stream->seek(0);
    251270    _header.read(_stream);
Note: See TracChangeset for help on using the changeset viewer.