Index: trunk/BNC/bncephuser.h
===================================================================
--- trunk/BNC/bncephuser.h	(revision 2904)
+++ trunk/BNC/bncephuser.h	(revision 2905)
@@ -64,5 +64,5 @@
   void slotNewEphGalileo(galileoephemeris galeph);
 
- private:
+ protected:
 
   class t_ephPair {
Index: trunk/BNC/bncpppclient.cpp
===================================================================
--- trunk/BNC/bncpppclient.cpp	(revision 2904)
+++ trunk/BNC/bncpppclient.cpp	(revision 2905)
@@ -86,13 +86,4 @@
           ((bncApp*)qApp), SLOT(slotMessage(const QByteArray,bool)));
 
-  connect(((bncApp*)qApp), SIGNAL(newEphGPS(gpsephemeris)),
-          this, SLOT(slotNewEphGPS(gpsephemeris)));
-
-  connect(((bncApp*)qApp), SIGNAL(newEphGlonass(glonassephemeris)),
-          this, SLOT(slotNewEphGlonass(glonassephemeris)));
-
-  connect(((bncApp*)qApp), SIGNAL(newEphGalileo(galileoephemeris)),
-          this, SLOT(slotNewEphGalileo(galileoephemeris)));
-
   connect(((bncApp*)qApp), SIGNAL(newCorrections(QList<QString>)),
           this, SLOT(slotNewCorrections(QList<QString>)));
@@ -111,9 +102,4 @@
     delete _epoData.front();
     _epoData.pop();
-  }
-  QMapIterator<QString, t_ephPair*> it(_eph);
-  while (it.hasNext()) {
-    it.next();
-    delete it.value();
   }
   QMapIterator<QString, t_corr*> ic(_corr);
@@ -271,84 +257,4 @@
       delete satData;
     }
-  }
-}
-
-// 
-////////////////////////////////////////////////////////////////////////////
-void bncPPPclient::slotNewEphGPS(gpsephemeris gpseph) {
-  QMutexLocker locker(&_mutex);
-
-  QString prn = QString("G%1").arg(gpseph.satellite, 2, 10, QChar('0'));
-
-  if (_eph.contains(prn)) {
-    t_ephGPS* eLast = static_cast<t_ephGPS*>(_eph.value(prn)->last);
-    if ( (eLast->GPSweek() <  gpseph.GPSweek) || 
-         (eLast->GPSweek() == gpseph.GPSweek &&  
-          eLast->TOC()     <  gpseph.TOC) ) {
-      delete static_cast<t_ephGPS*>(_eph.value(prn)->prev);
-      _eph.value(prn)->prev = _eph.value(prn)->last;
-      _eph.value(prn)->last = new t_ephGPS();
-      static_cast<t_ephGPS*>(_eph.value(prn)->last)->set(&gpseph);
-    }
-  }
-  else {
-    t_ephGPS* eLast = new t_ephGPS();
-    eLast->set(&gpseph);
-    _eph.insert(prn, new t_ephPair());
-    _eph[prn]->last = eLast;
-  }
-}
-
-// 
-////////////////////////////////////////////////////////////////////////////
-void bncPPPclient::slotNewEphGlonass(glonassephemeris gloeph) {
-  QMutexLocker locker(&_mutex);
-
-  QString prn = QString("R%1").arg(gloeph.almanac_number, 2, 10, QChar('0'));
-
-  if (_eph.contains(prn)) {
-    int ww  = gloeph.GPSWeek;
-    int tow = gloeph.GPSTOW; 
-    updatetime(&ww, &tow, gloeph.tb*1000, 0);  // Moscow -> GPS
-    t_ephGlo* eLast = static_cast<t_ephGlo*>(_eph.value(prn)->last);
-    if (eLast->GPSweek() < ww || 
-        (eLast->GPSweek()  == ww &&  eLast->GPSweeks() <  tow)) {  
-      delete static_cast<t_ephGlo*>(_eph.value(prn)->prev);
-      _eph.value(prn)->prev = _eph.value(prn)->last;
-      _eph.value(prn)->last = new t_ephGlo();
-      static_cast<t_ephGlo*>(_eph.value(prn)->last)->set(&gloeph);
-    }
-  }
-  else {
-    t_ephGlo* eLast = new t_ephGlo();
-    eLast->set(&gloeph);
-    _eph.insert(prn, new t_ephPair());
-    _eph[prn]->last = eLast;
-  }
-}
-
-// 
-////////////////////////////////////////////////////////////////////////////
-void bncPPPclient::slotNewEphGalileo(galileoephemeris galeph) {
-  QMutexLocker locker(&_mutex);
-
-  QString prn = QString("E%1").arg(galeph.satellite, 2, 10, QChar('0'));
-
-  if (_eph.contains(prn)) {
-    t_ephGal* eLast = static_cast<t_ephGal*>(_eph.value(prn)->last);
-    if ( (eLast->GPSweek() <  galeph.Week) || 
-         (eLast->GPSweek() == galeph.Week &&  
-          eLast->TOC()     <  galeph.TOC) ) {
-      delete static_cast<t_ephGal*>(_eph.value(prn)->prev);
-      _eph.value(prn)->prev = _eph.value(prn)->last;
-      _eph.value(prn)->last = new t_ephGal();
-      static_cast<t_ephGal*>(_eph.value(prn)->last)->set(&galeph);
-    }
-  }
-  else {
-    t_ephGal* eLast = new t_ephGal();
-    eLast->set(&galeph);
-    _eph.insert(prn, new t_ephPair());
-    _eph[prn]->last = eLast;
   }
 }
Index: trunk/BNC/bncpppclient.h
===================================================================
--- trunk/BNC/bncpppclient.h	(revision 2904)
+++ trunk/BNC/bncpppclient.h	(revision 2905)
@@ -27,12 +27,6 @@
 
 #include <queue>
-#include <QtNetwork>
-
-#include <newmat.h>
-
-#include "bncconst.h"
-#include "bnctime.h"
+#include "bncephuser.h"
 #include "RTCM/GPSDecoder.h"
-#include "RTCM3/ephemeris.h"
 
 class bncModel;
@@ -99,23 +93,4 @@
 };
 
-class t_corr {
- public:
-  t_corr() {
-    raoSet  = false;
-    dClkSet = false;
-  }
-  bool ready() {return raoSet && dClkSet;}
-  bncTime       tt;
-  int          iod;
-  double       dClk;
-  double       dotDClk;
-  double       dotDotDClk;
-  ColumnVector rao;
-  ColumnVector dotRao;
-  ColumnVector dotDotRao;
-  bool         raoSet;
-  bool         dClkSet;
-};
-
 class t_bias {
  public:
@@ -131,5 +106,5 @@
 };
 
-class bncPPPclient : public QObject {
+class bncPPPclient : public bncEphUser {
  Q_OBJECT
 
@@ -140,7 +115,4 @@
 
  public slots:
-  void slotNewEphGPS(gpsephemeris gpseph);
-  void slotNewEphGlonass(glonassephemeris gloeph);
-  void slotNewEphGalileo(galileoephemeris galeph);
   void slotNewCorrections(QList<QString> corrList);
 
@@ -164,18 +136,4 @@
   };
 
-  class t_ephPair {
-   public:
-    t_ephPair() {
-      last = 0;
-      prev = 0;
-    }
-    ~t_ephPair() {
-      delete last;
-      delete prev;
-    }
-    t_eph* last;
-    t_eph* prev;
-  };
-
   t_irc getSatPos(const bncTime& tt, const QString& prn, 
                   ColumnVector& xc, ColumnVector& vv);
@@ -187,6 +145,4 @@
 
   QByteArray              _staID;
-  QMutex                  _mutex;
-  QMap<QString, t_ephPair*> _eph;
   QMap<QString, t_corr*>  _corr;
   bncTime                 _corr_tt;
