MultiFormatNavDataFactory_T.cpp
Go to the documentation of this file.
1 //==============================================================================
2 //
3 // This file is part of GNSSTk, the ARL:UT GNSS Toolkit.
4 //
5 // The GNSSTk is free software; you can redistribute it and/or modify
6 // it under the terms of the GNU Lesser General Public License as published
7 // by the Free Software Foundation; either version 3.0 of the License, or
8 // any later version.
9 //
10 // The GNSSTk is distributed in the hope that it will be useful,
11 // but WITHOUT ANY WARRANTY; without even the implied warranty of
12 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 // GNU Lesser General Public License for more details.
14 //
15 // You should have received a copy of the GNU Lesser General Public
16 // License along with GNSSTk; if not, write to the Free Software Foundation,
17 // Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
18 //
19 // This software was developed by Applied Research Laboratories at the
20 // University of Texas at Austin.
21 // Copyright 2004-2022, The Board of Regents of The University of Texas System
22 //
23 //==============================================================================
24 
25 
26 //==============================================================================
27 //
28 // This software was developed by Applied Research Laboratories at the
29 // University of Texas at Austin, under contract to an agency or agencies
30 // within the U.S. Department of Defense. The U.S. Government retains all
31 // rights to use, duplicate, distribute, disclose, or release this software.
32 //
33 // Pursuant to DoD Directive 523024
34 //
35 // DISTRIBUTION STATEMENT A: This software has been approved for public
36 // release, distribution is unlimited.
37 //
38 //==============================================================================
40 #include "RinexNavDataFactory.hpp"
41 #include "SP3NavDataFactory.hpp"
42 #include "TestUtil.hpp"
43 #include "GPSLNavEph.hpp"
44 #include "GPSLNavHealth.hpp"
45 #include "OrbitDataSP3.hpp"
46 #include "DebugTrace.hpp"
47 
48 namespace gnsstk
49 {
50  std::ostream& operator<<(std::ostream& s, gnsstk::NavValidityType e)
51  {
52  s << StringUtils::asString(e);
53  return s;
54  }
55 
56  std::ostream& operator<<(std::ostream& s, gnsstk::NavMessageType e)
57  {
58  s << StringUtils::asString(e);
59  return s;
60  }
61 
62  std::ostream& operator<<(std::ostream& s, gnsstk::SatelliteSystem e)
63  {
64  s << StringUtils::asString(e);
65  return s;
66  }
67 
68  std::ostream& operator<<(std::ostream& s, gnsstk::CarrierBand e)
69  {
70  s << StringUtils::asString(e);
71  return s;
72  }
73 
74  std::ostream& operator<<(std::ostream& s, gnsstk::TrackingCode e)
75  {
76  s << StringUtils::asString(e);
77  return s;
78  }
79 
80  std::ostream& operator<<(std::ostream& s, gnsstk::NavType e)
81  {
82  s << StringUtils::asString(e);
83  return s;
84  }
85 
86  std::ostream& operator<<(std::ostream& s,
87  const gnsstk::NavMessageTypeSet& nmts)
88  {
89  s << "{";
90  for (const auto& i : nmts)
91  {
92  s << " " << gnsstk::StringUtils::asString(i);
93  }
94  s << " }";
95  return s;
96  }
97 }
98 
102 {
103 public:
106  { return data; }
107  static std::shared_ptr<gnsstk::NavDataFactoryMap> getFactories()
108  { return factories(); }
109 };
110 
113 {
114 public:
116  { return data; }
118  { return navValidity; }
120  { return procNavTypes; }
121 };
122 
123 
128 {
129 public:
131  unsigned constructorTest();
132  unsigned findTest();
133  unsigned editTest();
134  unsigned clearTest();
135  unsigned sizeTest();
136  unsigned countTest();
137  unsigned numSignalsTest();
138  unsigned numSatellitesTest();
139  unsigned setValidityFilterTest();
140  unsigned setTypeFilterTest();
141  unsigned addTypeFilterTest();
143  unsigned loadIntoMapTest();
144  unsigned getFactoryTest();
145 };
146 
147 
150 {
151  TUDEF("MultiFormatNavDataFactory", "MultiFormatNavDataFactory");
153  // Check for expected signal support. The
154  // GNSSTKFormatInitializer_T test takes care of making sure the
155  // actual correct factories are added.
157  for (const auto& i : rinFact.supportedSignals)
158  {
159  TUASSERT(fact.supportedSignals.count(i));
160  }
162  for (const auto& i : sp3Fact.supportedSignals)
163  {
164  TUASSERT(fact.supportedSignals.count(i));
165  }
166  TURETURN();
167 }
168 
169 
172 {
173  TUDEF("MultiFormatNavDataFactory", "find");
180  std::string dpath = gnsstk::getPathData() + gnsstk::getFileSep();
181  gnsstk::CivilTime civ1a(2015, 7, 19, 16, 0, 0, gnsstk::TimeSystem::GPS);
182  gnsstk::CivilTime civ1b(2015, 7, 19, 18, 0, 0, gnsstk::TimeSystem::GPS);
183  gnsstk::NavDataPtr nd1a, nd1b;
184  TUCSM("loadIntoMap");
185  TUASSERT(fact.addDataSource(dpath + "arlm2000.15n"));
186  TUASSERT(fact.addDataSource(dpath + "test_input_sp3_nav_ephemerisData.sp3"));
187  TUASSERT(fact.find(nmid1a, civ1a, nd1a, gnsstk::SVHealth::Any,
190  // nd1a should be a pointer to a GPSLNavEph
191  gnsstk::GPSLNavEph *ephPtr = dynamic_cast<gnsstk::GPSLNavEph*>(nd1a.get());
192  TUASSERT(ephPtr != nullptr);
193  if (ephPtr == nullptr)
194  TURETURN();
195  // make sure we got the ephemeris we expected.
196  TUASSERTE(uint16_t, 0x4f, ephPtr->iodc);
197  // This tests getting an updated ephemeris, i.e. a Toe not
198  // aligned to 2 hours
199  TUASSERT(fact.find(nmid1a, civ1b, nd1b, gnsstk::SVHealth::Any,
202  // nd1b should be a pointer to a GPSLNavEph
203  ephPtr = dynamic_cast<gnsstk::GPSLNavEph*>(nd1b.get());
204  TUASSERT(ephPtr != nullptr);
205  if (ephPtr == nullptr)
206  TURETURN();
207  // make sure we got the ephemeris we expected.
208  TUASSERTE(uint16_t, 0x0a, ephPtr->iodc);
209  // now check for SP3 data
217  ct = gnsstk::CivilTime(1997,4,6,6,17,36,gnsstk::TimeSystem::GPS);
218  gnsstk::NavDataPtr nd2;
219  TUASSERT(fact.find(nmid2, ct, nd2, gnsstk::SVHealth::Any,
222  gnsstk::OrbitDataSP3 *uut = dynamic_cast<gnsstk::OrbitDataSP3*>(nd2.get());
223  if (uut == nullptr)
224  TURETURN();
225  // NavData
228  uut->signal.messageType);
229  TUASSERTE(gnsstk::SatID, expSat2, uut->signal.sat);
230  TUASSERTE(gnsstk::SatID, expSat2, uut->signal.xmitSat);
232  uut->signal.system);
236  // OrbitData
237  // OrbitDataSP3
238  TUASSERTFE(-15643.515779275317982, uut->pos[0]);
239  TUASSERTFE(17046.376009584488202, uut->pos[1]);
240  TUASSERTFE(12835.522993916223641, uut->pos[2]);
241  TUASSERTFE(0, uut->posSig[0]);
242  TUASSERTFE(0, uut->posSig[1]);
243  TUASSERTFE(0, uut->posSig[2]);
244  TUASSERTFE(4118.735914736347695, uut->vel[0]);
245  TUASSERTFE(-16208.344018608038823, uut->vel[1]);
246  TUASSERTFE(26087.591273316520528, uut->vel[2]);
247  TUASSERTFE(0, uut->velSig[0]);
248  TUASSERTFE(0, uut->velSig[1]);
249  TUASSERTFE(0, uut->velSig[2]);
250  TUASSERTFE(0, uut->acc[0]);
251  TUASSERTFE(0, uut->acc[1]);
252  TUASSERTFE(0, uut->acc[2]);
253  TUASSERTFE(0, uut->accSig[0]);
254  TUASSERTFE(0, uut->accSig[1]);
255  TUASSERTFE(0, uut->accSig[2]);
256  TUASSERTFE(411.55797411176871492, uut->clkBias);
257  TUASSERTFE(0, uut->biasSig);
258  TUASSERTFE(2.2909472663417080121e-06, uut->clkDrift);
259  TUASSERTFE(0, uut->driftSig);
260  TUASSERTFE(0, uut->clkDrRate);
261  TUASSERTFE(0, uut->drRateSig);
262  TURETURN();
263 }
264 
265 
268 {
269  TUDEF("MultiFormatNavDataFactory", "edit");
270  // time before any of the loaded data
271  gnsstk::CivilTime before(2000, 1, 1, 0, 0, 0, gnsstk::TimeSystem::GPS);
272  gnsstk::CivilTime between(2005, 1, 1, 0, 0, 0, gnsstk::TimeSystem::GPS);
285  std::string dpath = gnsstk::getPathData() + gnsstk::getFileSep();
286  // get pointers to known factories to verify results
287  gnsstk::RinexNavDataFactory *rinFact = nullptr;
288  gnsstk::SP3NavDataFactory *sp3Fact = nullptr;
289  for (auto& i : *(TestClass::getFactories()))
290  {
291  gnsstk::NavDataFactory *p = i.second.get();
292  if (rinFact == nullptr)
293  {
294  rinFact = dynamic_cast<gnsstk::RinexNavDataFactory*>(p);
295  }
296  if (sp3Fact == nullptr)
297  {
298  sp3Fact = dynamic_cast<gnsstk::SP3NavDataFactory*>(p);
299  }
300  }
301  TUASSERT(rinFact != nullptr);
302  TUASSERT(sp3Fact != nullptr);
303  if ((rinFact == nullptr) || (sp3Fact == nullptr))
304  {
305  // don't try to continue with tests that will cause seg faults.
306  TURETURN();
307  }
308  TUCSM("loadIntoMap");
309  TUASSERT(fact.addDataSource(dpath + "arlm2000.15n"));
310  TUASSERTE(size_t, 507, rinFact->size());
311  TUASSERT(fact.addDataSource(dpath + "test_input_SP3a.sp3"));
312  TUASSERTE(size_t, 232, sp3Fact->size());
313 
314  TUCSM("edit");
315  // remove nothing
317  TUASSERTE(size_t, 507, rinFact->size());
318  TUASSERTE(size_t, 232, sp3Fact->size());
319  // remove a time span that covers all of the SP3 data but none
320  // of the RINEX data.
321  TUCATCH(fact.edit(before, between));
322  TUASSERTE(size_t, 507, rinFact->size());
323  TUASSERTE(size_t, 0, sp3Fact->size());
324  // reload SP3 data for next test
325  TUCSM("loadIntoMap");
326  TUASSERT(fact.addDataSource(dpath + "test_input_SP3a.sp3"));
327  TUASSERTE(size_t, 232, sp3Fact->size());
328  TUCSM("edit");
329  // remove a time span that covers all of the RINEX data but none
330  // of the SP3 data.
332  TUASSERTE(size_t, 0, rinFact->size());
333  TUASSERTE(size_t, 232, sp3Fact->size());
334  // reload RINEX data for next test
335  TUCSM("loadIntoMap");
336  TUASSERT(fact.addDataSource(dpath + "arlm2000.15n"));
337  TUASSERTE(size_t, 507, rinFact->size());
338  // verify initial conditions
339  TUCSM("numSatellites");
340  TUASSERTE(size_t, 33, rinFact->numSatellites());
341  TUASSERTE(size_t, 29, sp3Fact->numSatellites());
342  // remove nothing - time
343  TUCSM("edit");
344  TUCATCH(fact.edit(gnsstk::CommonTime::BEGINNING_OF_TIME, before, satID2a));
345  TUASSERTE(size_t, 507, rinFact->size());
346  TUASSERTE(size_t, 232, sp3Fact->size());
347  // remove nothing, this time because the satellite ID isn't present
350  TUASSERTE(size_t, 507, rinFact->size());
351  TUASSERTE(size_t, 232, sp3Fact->size());
352  // remove nothing, this time because the signal isn't present
355  TUASSERTE(size_t, 507, rinFact->size());
356  TUASSERTE(size_t, 232, sp3Fact->size());
357  TURETURN();
358 }
359 
360 
363 {
364  TUDEF("MultiFormatNavDataFactory", "clear");
366  std::string dpath = gnsstk::getPathData() + gnsstk::getFileSep();
367  TUCSM("loadIntoMap");
368  TUASSERT(fact.addDataSource(dpath + "arlm2000.15n"));
369  TUASSERT(fact.addDataSource(dpath + "test_input_SP3a.sp3"));
370  TUCSM("size");
371  TUASSERTE(size_t, 507+232, fact.size());
372  TUCSM("clear");
373  TUCATCH(fact.clear());
374  TUASSERTE(size_t, 0, fact.size());
375  TURETURN();
376 }
377 
378 
381 {
382  TUDEF("MultiFormatNavDataFactory", "size");
384  std::string dpath = gnsstk::getPathData() + gnsstk::getFileSep();
385  TUCSM("loadIntoMap");
386  TUASSERT(fact.addDataSource(dpath + "arlm2000.15n"));
387  TUASSERT(fact.addDataSource(dpath + "test_input_SP3a.sp3"));
388  TUCSM("size");
389  TUASSERTE(size_t, 507+232, fact.size());
390  TURETURN();
391 }
392 
393 
396 {
397  TUDEF("MultiFormatNavDataFactory", "count");
399  std::string dpath = gnsstk::getPathData() + gnsstk::getFileSep();
400  TUCSM("loadIntoMap");
401  TUASSERT(uut.addDataSource(dpath + "arlm2000.15n"));
402  TUASSERT(uut.addDataSource(dpath + "test_input_SP3a.sp3"));
403  TUCSM("count");
404  size_t totalCount = uut.size();
414  key1.sat.makeWild();
415  key1.xmitSat.makeWild();
416  // debug enable. Should probably make this a method and apply
417  // it to all managed factories.
418  // std::shared_ptr<gnsstk::SP3NavDataFactory> sp3 =
419  // uut.getFactory<gnsstk::SP3NavDataFactory>();
420  // std::shared_ptr<gnsstk::RinexNavDataFactory> rinex =
421  // uut.getFactory<gnsstk::RinexNavDataFactory>();
422  // sp3->debugLevel = 1;
423  // rinex->debugLevel = 1;
424  //
425  // key1, being a complete wildcard, should yield the same
426  // results as size()
427  TUASSERTE(size_t, totalCount, uut.count(key1));
428  // sp3->debugLevel = 0;
429  // rinex->debugLevel = 0;
430  TURETURN();
431 }
432 
433 
436 {
437  TUDEF("MultiFormatNavDataFactory", "numSignals");
443  std::string dpath = gnsstk::getPathData() + gnsstk::getFileSep();
444  TUCSM("loadIntoMap");
445  TUASSERT(fact.addDataSource(dpath + "arlm2000.15n"));
446  TUASSERT(fact.addDataSource(dpath + "test_input_SP3a.sp3"));
447  TUCSM("numSignals");
448  // should just be one, L1 C/A LNav
449  // But because of the RINEX kludge for time offset data, we get
450  // two (there's no way to know where the time offset data in a
451  // RINEX file came from).
452  TUASSERTE(size_t, 2, fact.numSignals());
453  for (const auto& fi : *(TestClass::getFactories()))
454  {
455  TestFactory *tfp = reinterpret_cast<TestFactory*>(fi.second.get());
456  TUASSERT(tfp != nullptr);
457  if (tfp == nullptr)
458  {
459  continue;
460  }
461  for (const auto& di : tfp->getData())
462  {
463  if (di.first == gnsstk::NavMessageType::TimeOffset)
464  {
465  // Just skip checking the TimeOffset signal ID because
466  // it's bunk for RINEX.
467  continue;
468  }
469  for (const auto& sigi : di.second)
470  {
471  TUASSERTE(gnsstk::NavSignalID, expSig, sigi.first);
472  }
473  }
474  }
475  TURETURN();
476 }
477 
478 
481 {
482  TUDEF("MultiFormatNavDataFactory", "numSatellites");
484  std::string dpath = gnsstk::getPathData() + gnsstk::getFileSep();
485  TUCSM("loadIntoMap");
486  TUASSERT(fact.addDataSource(dpath + "arlm2000.15n"));
487  TUASSERT(fact.addDataSource(dpath + "test_input_SP3a.sp3"));
488  TUCSM("numSatellites");
489  TUASSERTE(size_t, 34, fact.numSatellites());
490  TURETURN();
491 }
492 
493 
496 {
497  TUDEF("MultiFormatNavDataFactory", "setValidityFilter");
498  TestClass mfact;
499  mfact.setValidityFilter(gnsstk::NavValidityType::ValidOnly);
500  for (const auto& i : *(TestClass::getFactories()))
501  {
502  TestFactory *tfp = reinterpret_cast<TestFactory*>(i.second.get());
504  tfp->getValidityFilter());
505  }
506  mfact.setValidityFilter(gnsstk::NavValidityType::Any);
507  for (const auto& i : *(TestClass::getFactories()))
508  {
509  TestFactory *tfp = reinterpret_cast<TestFactory*>(i.second.get());
511  tfp->getValidityFilter());
512  }
513  TURETURN();
514 }
515 
516 
519 {
520  TUDEF("MultiFormatNavDataFactory", "setTypeFilter");
521  TestClass mfact;
524  mfact.setTypeFilter(nmts1);
525  for (const auto& i : *(TestClass::getFactories()))
526  {
527  TestFactory *tfp = reinterpret_cast<TestFactory*>(i.second.get());
529  }
530  mfact.setTypeFilter(nmts2);
531  for (const auto& i : *(TestClass::getFactories()))
532  {
533  TestFactory *tfp = reinterpret_cast<TestFactory*>(i.second.get());
535  }
536  mfact.setTypeFilter(gnsstk::allNavMessageTypes);
537  for (const auto& i : *(TestClass::getFactories()))
538  {
539  TestFactory *tfp = reinterpret_cast<TestFactory*>(i.second.get());
541  tfp->getTypeFilter());
542  }
543  TURETURN();
544 }
545 
546 
549 {
550  TUDEF("MultiFormatNavDataFactory", "clearTypeFilter");
551  TestClass mfact;
553  for (const auto& i : *(TestClass::getFactories()))
554  {
555  TestFactory *tfp = reinterpret_cast<TestFactory*>(i.second.get());
557  tfp->getTypeFilter());
558  }
559  TUCATCH(mfact.clearTypeFilter());
560  for (const auto& i : *(TestClass::getFactories()))
561  {
562  TestFactory *tfp = reinterpret_cast<TestFactory*>(i.second.get());
563  TUASSERT(tfp->getTypeFilter().empty());
564  }
565  TUCSM("addTypeFilter");
566  TUCATCH(mfact.addTypeFilter(gnsstk::NavMessageType::Almanac));
567  for (const auto& i : *(TestClass::getFactories()))
568  {
569  TestFactory *tfp = reinterpret_cast<TestFactory*>(i.second.get());
571  }
572  // Set the type filter back to all so that other tests work.
573  TUCATCH(mfact.setTypeFilter(gnsstk::allNavMessageTypes));
574  for (const auto& i : *(TestClass::getFactories()))
575  {
576  TestFactory *tfp = reinterpret_cast<TestFactory*>(i.second.get());
578  tfp->getTypeFilter());
579  }
580  TURETURN();
581 }
582 
583 
586 {
587  TUDEF("MultiFormatNavDataFactory", "loadIntoMap");
588 
589  // get pointers to known factories to verify results
590  gnsstk::RinexNavDataFactory *rinFact = nullptr;
591  gnsstk::SP3NavDataFactory *sp3Fact = nullptr;
592  for (auto& i : *(TestClass::getFactories()))
593  {
594  gnsstk::NavDataFactory *p = i.second.get();
595  if (rinFact == nullptr)
596  {
597  rinFact = dynamic_cast<gnsstk::RinexNavDataFactory*>(p);
598  }
599  if (sp3Fact == nullptr)
600  {
601  sp3Fact = dynamic_cast<gnsstk::SP3NavDataFactory*>(p);
602  }
603  }
604  TUASSERT(rinFact != nullptr);
605  TUASSERT(sp3Fact != nullptr);
606  if ((rinFact == nullptr) || (sp3Fact == nullptr))
607  {
608  // don't try to continue with tests that will cause seg faults.
609  TURETURN();
610  }
611 
612  // test loading RINEX 2 nav
614  std::string f2name = gnsstk::getPathData() + gnsstk::getFileSep() +
615  "arlm2000.15n";
616  // this should implicitly load into the data map
617  TUASSERT(fact.addDataSource(f2name));
618  TUASSERTE(size_t, 507, rinFact->size());
619 
620  // test loading SP3 nav
621  std::string f3name = gnsstk::getPathData() + gnsstk::getFileSep() +
622  "test_input_SP3a.sp3";
623  TUASSERT(fact.addDataSource(f3name));
624  TUASSERTE(size_t, 232, sp3Fact->size());
625 
626  // Not testing filter combinations here. This should be
627  // implicitly tested by the individual factories'
628  // loadIntoMapTests and the
629  // setTypeFilterTest/setValidityFilterTest methods here.
630 
631  TURETURN();
632 }
633 
634 
637 {
638  TUDEF("MultiFormatNavDataFactory", "getFactory");
640  std::shared_ptr<gnsstk::SP3NavDataFactory> sp3fact =
642  TUASSERTE(bool, true, static_cast<bool>(sp3fact));
643  std::shared_ptr<gnsstk::Exception> shouldFail =
645  TUASSERTE(bool, false, static_cast<bool>(shouldFail));
646  TURETURN();
647 }
648 
649 
650 int main()
651 {
652  MultiFormatNavDataFactory_T testClass;
653  unsigned errorTotal = 0;
654 
655  errorTotal += testClass.constructorTest();
656  errorTotal += testClass.findTest();
657  errorTotal += testClass.editTest();
658  errorTotal += testClass.clearTest();
659  errorTotal += testClass.sizeTest();
660  errorTotal += testClass.countTest();
661  errorTotal += testClass.numSignalsTest();
662  errorTotal += testClass.numSatellitesTest();
663  errorTotal += testClass.setValidityFilterTest();
664  errorTotal += testClass.setTypeFilterTest();
665  errorTotal += testClass.addTypeFilterTest();
666  errorTotal += testClass.loadIntoMapTest();
667  errorTotal += testClass.getFactoryTest();
668 
669  std::cout << "Total Failures for " << __FILE__ << ": " << errorTotal
670  << std::endl;
671 
672  return errorTotal;
673 }
gnsstk::MultiFormatNavDataFactory::size
size_t size() const override
Return the number of nav messages in all factories.
Definition: MultiFormatNavDataFactory.cpp:278
gnsstk::NavDataPtr
std::shared_ptr< NavData > NavDataPtr
Factories instantiate these in response to find() requests.
Definition: NavData.hpp:62
gnsstk::NavSignalID::nav
NavType nav
Navigation message structure of this signal.
Definition: NavSignalID.hpp:96
gnsstk::NavMessageTypeSet
std::set< NavMessageType > NavMessageTypeSet
Set of message types, used by NavLibrary and NavDataFactory.
Definition: NavMessageType.hpp:76
gnsstk::OrbitDataSP3::posSig
Triple posSig
Standard deviation of position.
Definition: OrbitDataSP3.hpp:91
TUCSM
#define TUCSM(METHOD)
Definition: TestUtil.hpp:59
gnsstk::MultiFormatNavDataFactory::numSatellites
size_t numSatellites() const override
Return the number of distinct signals including PRN, in factories.
Definition: MultiFormatNavDataFactory.cpp:342
gnsstk::NavMessageID
Class used to identify/categorize navigation message data.
Definition: NavMessageID.hpp:52
TestFactory::getValidityFilter
gnsstk::NavValidityType getValidityFilter() const
Definition: MultiFormatNavDataFactory_T.cpp:117
TestFactory
Expose NavDataFactory protected members.
Definition: MultiFormatNavDataFactory_T.cpp:112
gnsstk::OrbitDataSP3::driftSig
double driftSig
SV clock drift std deviation in microseconds/sec.
Definition: OrbitDataSP3.hpp:99
MultiFormatNavDataFactory_T::clearTest
unsigned clearTest()
Definition: MultiFormatNavDataFactory_T.cpp:362
gnsstk::SatID::makeWild
void makeWild()
Definition: SatID.cpp:74
MultiFormatNavDataFactory_T::findTest
unsigned findTest()
Definition: MultiFormatNavDataFactory_T.cpp:171
MultiFormatNavDataFactory_T::constructorTest
unsigned constructorTest()
Make sure the constructor does what it's supposed to.
Definition: MultiFormatNavDataFactory_T.cpp:149
TUCATCH
#define TUCATCH(STATEMENT)
Definition: TestUtil.hpp:193
gnsstk::MultiFormatNavDataFactory::find
bool find(const NavMessageID &nmid, const CommonTime &when, NavDataPtr &navOut, SVHealth xmitHealth, NavValidityType valid, NavSearchOrder order) override
Definition: MultiFormatNavDataFactory.cpp:66
gnsstk::NavMessageMap
std::map< NavMessageType, NavSatMap > NavMessageMap
Map nav message type to the rest of the storage.
Definition: NavData.hpp:71
MultiFormatNavDataFactory_T::editTest
unsigned editTest()
Definition: MultiFormatNavDataFactory_T.cpp:267
gnsstk::OrbitDataSP3::vel
Triple vel
ECEF velocity (dm/s) of satellite at time.
Definition: OrbitDataSP3.hpp:92
TUASSERTE
#define TUASSERTE(TYPE, EXP, GOT)
Definition: TestUtil.hpp:81
MultiFormatNavDataFactory_T::getFactoryTest
unsigned getFactoryTest()
Definition: MultiFormatNavDataFactory_T.cpp:636
gnsstk::CarrierBand
CarrierBand
Definition: CarrierBand.hpp:54
gnsstk::MultiFormatNavDataFactory::count
size_t count(const NavMessageID &nmid) const override
Definition: MultiFormatNavDataFactory.cpp:298
gnsstk::NavMessageID::messageType
NavMessageType messageType
Definition: NavMessageID.hpp:97
gnsstk::NavSatelliteID
Definition: NavSatelliteID.hpp:57
gnsstk::allNavMessageTypes
const GNSSTK_EXPORT NavMessageTypeSet allNavMessageTypes
Definition: NavStatic.cpp:64
gnsstk::SatelliteSystem
SatelliteSystem
Supported satellite systems.
Definition: SatelliteSystem.hpp:55
gnsstk::OrbitDataSP3::velSig
Triple velSig
Standard deviation of velocity.
Definition: OrbitDataSP3.hpp:93
gnsstk::TrackingCode::Y
@ Y
Encrypted legacy GPS precise code.
gnsstk::CarrierBand::Any
@ Any
Used to match any carrier band.
gnsstk::SatID
Definition: SatID.hpp:89
gnsstk::StringUtils::asString
std::string asString(IonexStoreStrategy e)
Convert a IonexStoreStrategy to a whitespace-free string name.
Definition: IonexStoreStrategy.cpp:46
gnsstk::OrbitDataSP3::clkBias
double clkBias
SV clock bias in microseconds.
Definition: OrbitDataSP3.hpp:96
GPSLNavHealth.hpp
gnsstk::MultiFormatNavDataFactory::numSignals
size_t numSignals() const override
Return the number of distinct signals (ignoring PRN) in factories.
Definition: MultiFormatNavDataFactory.cpp:318
TestFactory::getTypeFilter
gnsstk::NavMessageTypeSet getTypeFilter() const
Definition: MultiFormatNavDataFactory_T.cpp:119
gnsstk::ObsID::band
CarrierBand band
Definition: ObsID.hpp:200
gnsstk::OrbitDataSP3::accSig
Triple accSig
Standard deviation of acceleration.
Definition: OrbitDataSP3.hpp:95
gnsstk::CommonTime::BEGINNING_OF_TIME
static const GNSSTK_EXPORT CommonTime BEGINNING_OF_TIME
earliest representable CommonTime
Definition: CommonTime.hpp:102
MultiFormatNavDataFactory_T::setValidityFilterTest
unsigned setValidityFilterTest()
Definition: MultiFormatNavDataFactory_T.cpp:495
MultiFormatNavDataFactory_T::setTypeFilterTest
unsigned setTypeFilterTest()
Definition: MultiFormatNavDataFactory_T.cpp:518
gnsstk::NavValidityType
NavValidityType
Definition: NavValidityType.hpp:53
gnsstk::NavData::signal
NavMessageID signal
Source signal identification for this navigation message data.
Definition: NavData.hpp:175
gnsstk
For Sinex::InputHistory.
Definition: BasicFramework.cpp:50
gnsstk::NavType::GPSLNAV
@ GPSLNAV
gnsstk::MultiFormatNavDataFactory::getFactory
std::shared_ptr< Fact > getFactory()
Definition: MultiFormatNavDataFactory.hpp:352
MultiFormatNavDataFactory_T::sizeTest
unsigned sizeTest()
Definition: MultiFormatNavDataFactory_T.cpp:380
MultiFormatNavDataFactory_T::numSatellitesTest
unsigned numSatellitesTest()
Definition: MultiFormatNavDataFactory_T.cpp:480
gnsstk::NavData::timeStamp
CommonTime timeStamp
Definition: NavData.hpp:173
gnsstk::MultiFormatNavDataFactory::clear
void clear() override
Remove all data from the internal store.
Definition: MultiFormatNavDataFactory.cpp:142
gnsstk::Exception
Definition: Exception.hpp:151
gnsstk::SatelliteSystem::GPS
@ GPS
gnsstk::SVHealth::Any
@ Any
Use in searches when you don't care about the SV health.
gnsstk::TrackingCode::CA
@ CA
Legacy GPS civil code.
gnsstk::CommonTime::END_OF_TIME
static const GNSSTK_EXPORT CommonTime END_OF_TIME
latest representable CommonTime
Definition: CommonTime.hpp:104
gnsstk::NavType::Any
@ Any
Used to match any nav code.
gnsstk::NavSignalID::obs
ObsID obs
Carrier, tracking code, etc.
Definition: NavSignalID.hpp:95
gnsstk::NavSignalID::system
SatelliteSystem system
GNSS for this signal.
Definition: NavSignalID.hpp:94
TUASSERT
#define TUASSERT(EXPR)
Definition: TestUtil.hpp:63
TestUtil.hpp
gnsstk::ObservationType::Any
@ Any
Used to match any observation type.
gnsstk::NavMessageType::Unknown
@ Unknown
Message type is not known or is uninitialized.
gnsstk::OrbitDataSP3::pos
Triple pos
ECEF position (km) of satellite at time.
Definition: OrbitDataSP3.hpp:90
gnsstk::NavDataFactoryWithStore::size
virtual size_t size() const
Return the number of nav messages in data.
Definition: NavDataFactoryWithStore.cpp:1005
gnsstk::MultiFormatNavDataFactory::edit
void edit(const CommonTime &fromTime, const CommonTime &toTime) override
Definition: MultiFormatNavDataFactory.cpp:110
TURETURN
#define TURETURN()
Definition: TestUtil.hpp:232
gnsstk::NavDataFactory::navValidity
NavValidityType navValidity
Definition: NavDataFactory.hpp:390
gnsstk::SatelliteSystem::Unknown
@ Unknown
MultiFormatNavDataFactory.hpp
gnsstk::NavValidityType::ValidOnly
@ ValidOnly
Only load/find nav messages that pass validity checks.
TestClass::getData
gnsstk::NavMessageMap & getData()
Grant access to protected data.
Definition: MultiFormatNavDataFactory_T.cpp:105
gnsstk::ObsID
Definition: ObsID.hpp:82
MultiFormatNavDataFactory_T
Definition: MultiFormatNavDataFactory_T.cpp:127
main
int main()
Definition: MultiFormatNavDataFactory_T.cpp:650
gnsstk::NavSatelliteID::sat
SatID sat
ID of satellite to which the nav data applies.
Definition: NavSatelliteID.hpp:169
gnsstk::operator<<
std::ostream & operator<<(std::ostream &s, const ObsEpoch &oe) noexcept
Definition: ObsEpochMap.cpp:54
gnsstk::CommonTime
Definition: CommonTime.hpp:84
gnsstk::MultiFormatNavDataFactory
Definition: MultiFormatNavDataFactory.hpp:74
gnsstk::ObsID::code
TrackingCode code
Definition: ObsID.hpp:201
gnsstk::CarrierBand::L1
@ L1
GPS L1, Galileo E1, SBAS L1, QZSS L1, BeiDou L1.
gnsstk::NavValidityType::Any
@ Any
Load/find nav messages regardless of validity checks.
TUDEF
#define TUDEF(CLASS, METHOD)
Definition: TestUtil.hpp:56
gnsstk::NavDataFactoryWithStore::numSatellites
virtual size_t numSatellites() const
Return the number of distinct signals including PRN, in the data.
Definition: NavDataFactoryWithStore.cpp:1145
example3.data
data
Definition: example3.py:22
gnsstk::OrbitDataSP3::clkDrift
double clkDrift
SV clock drift in s/s.
Definition: OrbitDataSP3.hpp:98
OrbitDataSP3.hpp
MultiFormatNavDataFactory_T::numSignalsTest
unsigned numSignalsTest()
Definition: MultiFormatNavDataFactory_T.cpp:435
gnsstk::OrbitDataSP3::acc
Triple acc
Acceleration (m/s/s) of satellite at time.
Definition: OrbitDataSP3.hpp:94
gnsstk::CivilTime
Definition: CivilTime.hpp:55
gnsstk::NavMessageType::TimeOffset
@ TimeOffset
Message containing information about time system offsets.
gnsstk::NavDataFactoryWithStore::data
NavMessageMap data
Internal storage of navigation data for User searches.
Definition: NavDataFactoryWithStore.hpp:456
gnsstk::NavSignalID
Class used to identify navigation data signal types.
Definition: NavSignalID.hpp:54
gnsstk::TrackingCode
TrackingCode
Definition: TrackingCode.hpp:64
TestClass::getFactories
static std::shared_ptr< gnsstk::NavDataFactoryMap > getFactories()
Definition: MultiFormatNavDataFactory_T.cpp:107
gnsstk::TimeSystem::GPS
@ GPS
GPS system time.
gnsstk::SP3NavDataFactory
Definition: SP3NavDataFactory.hpp:58
DebugTrace.hpp
gnsstk::NavMessageType
NavMessageType
Identify different types of navigation message data.
Definition: NavMessageType.hpp:59
gnsstk::OrbitDataSP3::clkDrRate
double clkDrRate
SV clock drift rate in s/s**2.
Definition: OrbitDataSP3.hpp:100
gnsstk::NavMessageType::Ephemeris
@ Ephemeris
Precision orbits for the transmitting SV.
gnsstk::RinexNavDataFactory
Definition: RinexNavDataFactory.hpp:57
TestClass
Make GroupPathCorrector instantiatable for testing.
Definition: GroupPathCorrector_T.cpp:56
gnsstk::OrbitDataSP3::biasSig
double biasSig
SV clock bias std deviation in microseconds.
Definition: OrbitDataSP3.hpp:97
TUASSERTFE
#define TUASSERTFE(EXP, GOT)
Definition: TestUtil.hpp:103
gnsstk::NavDataFactory
Definition: NavDataFactory.hpp:60
gnsstk::GPSLNavEph::iodc
uint16_t iodc
Issue Of Data-Clock for the ephemeris.
Definition: GPSLNavEph.hpp:98
gnsstk::OrbitDataSP3
Class for orbit information using SP3 data tables.
Definition: OrbitDataSP3.hpp:51
SP3NavDataFactory.hpp
MultiFormatNavDataFactory_T::countTest
unsigned countTest()
Definition: MultiFormatNavDataFactory_T.cpp:395
gnsstk::NavDataFactory::supportedSignals
NavSignalSet supportedSignals
Definition: NavDataFactory.hpp:379
gnsstk::NavSearchOrder::User
@ User
Return the latest message before the search time.
TestFactory::getData
gnsstk::NavMessageMap & getData()
Definition: MultiFormatNavDataFactory_T.cpp:115
gnsstk::GPSLNavEph
Class containing data elements unique to GPS LNav ephemerides.
Definition: GPSLNavEph.hpp:51
gnsstk::NavID
Definition: NavID.hpp:61
gnsstk::NavType
NavType
Supported navigation types.
Definition: NavType.hpp:58
GPSLNavEph.hpp
gnsstk::NavDataFactory::procNavTypes
NavMessageTypeSet procNavTypes
Definition: NavDataFactory.hpp:394
gnsstk::XmitAnt::Any
@ Any
When making comparisons in ObsID, matches any enumeration.
MultiFormatNavDataFactory_T::loadIntoMapTest
unsigned loadIntoMapTest()
Exercise loadIntoMap by loading data with different options in place.
Definition: MultiFormatNavDataFactory_T.cpp:585
gnsstk::NavSatelliteID::xmitSat
SatID xmitSat
ID of the satellite transmitting the nav data.
Definition: NavSatelliteID.hpp:170
gnsstk::OrbitDataSP3::drRateSig
double drRateSig
Definition: OrbitDataSP3.hpp:101
MultiFormatNavDataFactory_T::addTypeFilterTest
unsigned addTypeFilterTest()
Definition: MultiFormatNavDataFactory_T.cpp:548
gnsstk::TrackingCode::Any
@ Any
Used to match any tracking code.
gnsstk::NavMessageType::Almanac
@ Almanac
Low-precision orbits for other than the transmitting SV.
gnsstk::MultiFormatNavDataFactory::addDataSource
bool addDataSource(const std::string &source) override
Definition: MultiFormatNavDataFactory.cpp:441
gnsstk::CarrierBand::L5
@ L5
GPS L5, Galileo E5a, SBAS L5, QZSS L5, BeiDou B2a, NavIC L5.
RinexNavDataFactory.hpp
gnsstk::NavDataFactoryWithStore
Definition: NavDataFactoryWithStore.hpp:63


gnsstk
Author(s):
autogenerated on Wed Oct 25 2023 02:40:40