INSTINCT Code Coverage Report


Directory: src/
File: Navigation/GNSS/Satellite/internal/SatNavData.hpp
Date: 2025-02-07 16:54:41
Exec Total Coverage
Lines: 1 1 100.0%
Functions: 1 1 100.0%
Branches: 0 0 -%

Line Branch Exec Source
1 // This file is part of INSTINCT, the INS Toolkit for Integrated
2 // Navigation Concepts and Training by the Institute of Navigation of
3 // the University of Stuttgart, Germany.
4 //
5 // This Source Code Form is subject to the terms of the Mozilla Public
6 // License, v. 2.0. If a copy of the MPL was not distributed with this
7 // file, You can obtain one at https://mozilla.org/MPL/2.0/.
8
9 /// @file SatNavData.hpp
10 /// @brief Satellite Navigation data (to calculate SatNavData and clock)
11 /// @author T. Topp (topp@ins.uni-stuttgart.de)
12 /// @date 2022-12-07
13
14 #pragma once
15
16 #include <fmt/ostream.h>
17
18 #include "Clock.hpp"
19 #include "Orbit.hpp"
20 #include <cstdint>
21
22 namespace NAV
23 {
24
25 /// Satellite Navigation data (to calculate SatNavData and clock)
26 class SatNavData : public Clock, public Orbit
27 {
28 public:
29 /// @brief Child type
30 enum Type : uint8_t
31 {
32 GPSEphemeris, ///< GPS Broadcast Ephemeris
33 GalileoEphemeris, ///< Galileo Broadcast Ephemeris
34 GLONASSEphemeris, ///< GLONASS Broadcast Ephemeris
35 BeiDouEphemeris, ///< BeiDou Broadcast Ephemeris
36 QZSSEphemeris, ///< QZSS Broadcast Ephemeris
37 IRNSSEphemeris, ///< IRNSS Broadcast Ephemeris
38 SBASEphemeris, ///< SBAS Broadcast Ephemeris
39 };
40
41 /// @brief Constructor
42 /// @param[in] type Child type
43 /// @param[in] refTime Time when the information is calculated
44 explicit SatNavData(Type type, const InsTime& refTime);
45
46 /// @brief Destructor
47 82742 ~SatNavData() override = default;
48 /// @brief Copy constructor
49 SatNavData(const SatNavData&) = default;
50 /// @brief Move constructor
51 SatNavData(SatNavData&&) = default;
52 /// @brief Copy assignment operator
53 SatNavData& operator=(const SatNavData&) = delete;
54 /// @brief Move assignment operator
55 SatNavData& operator=(SatNavData&&) = delete;
56
57 /// @brief Checks whether the signal is healthy
58 [[nodiscard]] virtual bool isHealthy() const = 0;
59
60 /// @brief Child type (for down-casting)
61 const Type type;
62
63 /// Reference time of the information
64 InsTime refTime;
65 };
66
67 } // namespace NAV
68
69 #ifndef DOXYGEN_IGNORE
70
71 template<>
72 struct fmt::formatter<NAV::SatNavData::Type> : ostream_formatter
73 {};
74
75 #endif
76