Index: /trunk/GnssCenter/map_stations/map_stations.cpp
===================================================================
--- /trunk/GnssCenter/map_stations/map_stations.cpp	(revision 5406)
+++ /trunk/GnssCenter/map_stations/map_stations.cpp	(revision 5407)
@@ -28,4 +28,5 @@
 
 #include "map_stations.h"
+#include "thriftclient.h"
 
 using namespace std;
Index: /trunk/GnssCenter/map_stations/map_stations.h
===================================================================
--- /trunk/GnssCenter/map_stations/map_stations.h	(revision 5406)
+++ /trunk/GnssCenter/map_stations/map_stations.h	(revision 5407)
@@ -8,4 +8,5 @@
 class QwtPlot;
 class QwtPlotZoomer;
+class t_thriftClient;
 
 namespace GnssCenter {
@@ -30,14 +31,15 @@
 
  private:
-  QwtPlot*       _mapPlot;
-  QwtPlotZoomer* _mapPlotZoomer;
-  QPushButton*   _buttonClose;
-  QPushButton*   _buttonPrint;
-  QPushButton*   _buttonWhatsThis;
-  double         _minPointLat;
-  double         _maxPointLat;
-  double         _minPointLon;
-  double         _maxPointLon;
+  QwtPlot*        _mapPlot;
+  QwtPlotZoomer*  _mapPlotZoomer;
+  QPushButton*    _buttonClose;
+  QPushButton*    _buttonPrint;
+  QPushButton*    _buttonWhatsThis;
+  double          _minPointLat;
+  double          _maxPointLat;
+  double          _minPointLon;
+  double          _maxPointLon;
 
+  t_thriftClient* _thriftClinent;
 };
 
@@ -47,5 +49,5 @@
  public:
   virtual QWidget* create() {return new t_map_stations();} 
-  virtual QString getName() const {return QString("Map");}
+  virtual QString getName() const {return QString("Map of Stations");}
 };
 
Index: /trunk/GnssCenter/map_stations/map_stations.pro
===================================================================
--- /trunk/GnssCenter/map_stations/map_stations.pro	(revision 5406)
+++ /trunk/GnssCenter/map_stations/map_stations.pro	(revision 5407)
@@ -7,4 +7,7 @@
 DESTDIR              = ../plugins
 LIBS                 = -L../qwt -lqwt
+
+INCLUDEPATH         += /usr/local/include/thrift
+DEFINES             += HAVE_INTTYPES_H HAVE_NETINET_IN_H
 
 debug:OBJECTS_DIR   = .obj/debug
@@ -19,7 +22,9 @@
 PRE_TARGETDEPS      += gen-cpp
 
-HEADERS   = map_stations.h
+HEADERS   = map_stations.h \
+            thriftclient.h 
 
-SOURCES   = map_stations.cpp
+SOURCES   = map_stations.cpp \
+            thriftclient.cpp
 
 RESOURCES = map_stations.qrc
Index: /trunk/GnssCenter/map_stations/thriftclient.cpp
===================================================================
--- /trunk/GnssCenter/map_stations/thriftclient.cpp	(revision 5407)
+++ /trunk/GnssCenter/map_stations/thriftclient.cpp	(revision 5407)
@@ -0,0 +1,98 @@
+
+#include <iomanip>
+#include <sstream>
+#include <vector>
+
+#include "thriftclient.h"
+
+using namespace apache::thrift;
+using namespace apache::thrift::protocol;
+using namespace apache::thrift::transport;
+
+using namespace com::gpssolutions::rtnet;
+using namespace std;
+using namespace boost;
+
+// // Program
+// //////////////////////////////////////////////////////////////////////////////
+// int main(int argc, char **argv) {
+// 
+//   // Parse Input Options
+//   // -------------------
+//   map<string, string> OPT;
+//   parseCmdLine(argc, argv, OPT);
+//   if (OPT.find("port") == OPT.end()) {
+//     cerr << "usage: rtnetThriftClient [--host <host>] --port <port>" << endl;
+//     return 1;
+//   }
+//   string host = OPT.find("host") == OPT.end() ? "localhost" : OPT["host"];
+//   int    port; istringstream(OPT["port"]) >> port;
+// 
+//   shared_ptr<TSocket>     socket(new TSocket(host, port));
+//   shared_ptr<TTransport>  transport(new TBufferedTransport(socket)); 
+//   shared_ptr<TProtocol>   protocol(new TBinaryProtocol(transport));
+//   shared_ptr<RtnetDataIf> dataHandler(new t_thriftClient());
+//   shared_ptr<TProcessor>  processor(new RtnetDataProcessor(dataHandler));
+// 
+//   try {
+//     transport->open();
+// 
+//     while (processor->process(protocol,protocol,0)) {}
+// 
+//     transport->close();
+//   } 
+//   catch (TException& e) {
+//     cerr << "Caught an exception generated by Thrift: " << e.what() << endl;
+//     return 1;
+//   } 
+//   catch (...) {
+//     cerr << "Unknown exception" << endl;
+//     return 1;
+//   }
+// 
+//   return 0;
+// }
+
+// Handle Satellite Positions
+//////////////////////////////////////////////////////////////////////////////
+void t_thriftClient::
+handleSatelliteXYZ(const vector<SatelliteXYZ>& svXYZList) {
+  cout.setf(ios::fixed);
+  for (unsigned ii = 0; ii < svXYZList.size(); ii++) {
+//    const SatelliteXYZ& sat = svXYZList[ii];
+//    cout << unsigned(sat.ID) << ' '
+//         << setprecision(3) << sat.xyz.x << ' '
+//         << setprecision(3) << sat.xyz.y << ' '
+//         << setprecision(3) << sat.xyz.z << endl;
+  }
+//  cout << endl;
+}
+
+// Handle Station Info
+//////////////////////////////////////////////////////////////////////////////
+void t_thriftClient::
+handleStationInfo(const vector<StationInfo>& stationList) {
+  for (unsigned ii = 0; ii < stationList.size(); ii++) {
+    const StationInfo& staInfo = stationList[ii];
+    _stationCrd[staInfo.ID]._x = staInfo.xyz.x;
+    _stationCrd[staInfo.ID]._y = staInfo.xyz.y;
+    _stationCrd[staInfo.ID]._z = staInfo.xyz.z;
+  }
+}
+
+// Handle Eoch Results
+//////////////////////////////////////////////////////////////////////////////
+void t_thriftClient::
+handleEpochResults(const RtnetEpoch& epoch) {
+  for (unsigned ii = 0; ii < epoch.stationResultList.size(); ii++) {
+    const StationResults& staRes = epoch.stationResultList[ii];
+    cout << staRes.stationName << ' '
+         << (int) staRes.nsv_gps_used << ' ' << (int) staRes.nsv_glonass_used << ' ';
+    if (_stationCrd.find(staRes.stationName) != _stationCrd.end()) {
+      cout << _stationCrd[staRes.stationName]._x << ' '
+           << _stationCrd[staRes.stationName]._y << ' '
+           << _stationCrd[staRes.stationName]._z;
+    }
+    cout << endl;
+  }
+}
Index: /trunk/GnssCenter/map_stations/thriftclient.h
===================================================================
--- /trunk/GnssCenter/map_stations/thriftclient.h	(revision 5407)
+++ /trunk/GnssCenter/map_stations/thriftclient.h	(revision 5407)
@@ -0,0 +1,45 @@
+#ifndef THRIFTCLIENT_H
+#define THRIFTCLIENT_H
+
+#include <string>
+#include <map>
+
+#include <transport/TSocket.h>
+#include <transport/TBufferTransports.h>
+#include <protocol/TBinaryProtocol.h>
+
+#include "gen-cpp/RtnetData.h"
+
+using namespace com::gpssolutions::rtnet;
+
+// Handler Class Definition
+//////////////////////////////////////////////////////////////////////////////
+class t_thriftClient : public com::gpssolutions::rtnet::RtnetDataIf {
+ public:
+  t_thriftClient() {}
+  ~t_thriftClient() {}
+
+  void startDataStream() {}
+  void registerRtnet(const RtnetInformation& info) {}
+  void handleZDAmb(const std::vector<ZDAmb>& ambList) {}
+  void handleDDAmbresBaselines(const std::vector<DDAmbresBaseline>& ambList) {}
+  void handleSatelliteXYZ(const std::vector<SatelliteXYZ>& svXYZList);
+  void handleStationInfo(const std::vector<StationInfo>& stationList);
+  void handleStationAuxInfo(const std::vector<StationAuxInfo>& stationAuxList) {}
+  void handleDGPSCorr(const std::vector<DGPSCorr>& dgpsList) {}
+  void handleSatelliteClock(const std::vector<SatelliteClock>& svList) {}
+  void handleEpochResults(const RtnetEpoch& epoch);
+
+ private:
+
+  class t_stationCrd {
+   public:
+    double _x;
+    double _y;
+    double _z;
+  };
+
+  std::map<std::string, t_stationCrd> _stationCrd;
+};
+
+#endif
