Changeset 6067 in ntrip


Ignore:
Timestamp:
Sep 7, 2014, 10:10:02 AM (10 years ago)
Author:
mervart
Message:
 
Location:
trunk/BNC/src/PPP_free
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/src/PPP_free/bncpppclient.cpp

    r6065 r6067  
    5555// Constructor
    5656////////////////////////////////////////////////////////////////////////////
    57 bncPPPclient::bncPPPclient(QByteArray staID, t_pppOptions* opt) : bncEphUser(false) {
     57bncPPPclient::bncPPPclient(QByteArray staID, const t_pppOptions* opt) : bncEphUser(false) {
    5858
    5959  _opt   = opt;
  • trunk/BNC/src/PPP_free/bncpppclient.h

    r6066 r6067  
    4040class bncPPPclient : public bncEphUser {
    4141 public:
    42   bncPPPclient(QByteArray staID, t_pppOptions* opt);
     42  bncPPPclient(QByteArray staID, const t_pppOptions* opt);
    4343  ~bncPPPclient();
    4444  void                putNewObs(const t_obs& pp);
  • trunk/BNC/src/PPP_free/pppClient.cpp

    r6051 r6067  
    5858// Global variable holding thread-specific pointers
    5959//////////////////////////////////////////////////////////////////////////////
    60 t_pppClient* CLIENT = 0;
     60t_pppClient* PPP_CLIENT = 0;
    6161
    6262// Static function returning thread-specific pointer
    6363//////////////////////////////////////////////////////////////////////////////
    6464t_pppClient* t_pppClient::instance() {
    65   return CLIENT;
     65  return PPP_CLIENT;
    6666}
    6767
     
    6969//////////////////////////////////////////////////////////////////////////////
    7070t_pppClient::t_pppClient(const t_pppOptions* opt) {
    71   _opt      = new t_pppOptions(*opt);
    72   _log      = new ostringstream();
    73   CLIENT = this;
     71  _opt       = new t_pppOptions(*opt);
     72  _log       = new ostringstream();
     73  _client    = new bncPPPclient(QByteArray(_opt->_roverName.c_str()), _opt);
     74  PPP_CLIENT = this;
    7475}
    7576
     
    7980  delete _log;
    8081  delete _opt;
     82  delete _client;
    8183}
    8284
  • trunk/BNC/src/PPP_free/pppClient.h

    r6051 r6067  
    77#include "ephemeris.h"
    88#include "pppOptions.h"
    9 
    10 class bncAntex;
     9#include "bncpppclient.h"
    1110
    1211namespace BNC_PPP {
     
    2322  void processEpoch(const std::vector<t_satObs*>& satObs, t_output* output);
    2423
     24  static t_pppClient* instance();
    2525  std::ostringstream& log() {return *_log;}
    26   const t_pppOptions* opt() const {return _opt;}
    27 
    28   static t_pppClient* instance();
    2926
    3027 private:
    31   std::ostringstream*       _log;
    32   t_pppOptions*             _opt;
     28  std::ostringstream* _log;
     29  t_pppOptions*       _opt;
     30  bncPPPclient*       _client;
    3331};
    3432
    3533}; // namespace BNC_PPP
    3634
    37 #define PPP_CLIENT (BNC_PPP::t_pppClient::instance())
    38 #define LOG        (BNC_PPP::t_pppClient::instance()->log())
    39 #define OPT        (BNC_PPP::t_pppClient::instance()->opt())
     35#define LOG (BNC_PPP::t_pppClient::instance()->log())
    4036
    4137#endif
Note: See TracChangeset for help on using the changeset viewer.