GNSS-SDR  0.0.19
An Open Source GNSS Software Defined Receiver
gnss_signal.h
Go to the documentation of this file.
1 /*!
2  * \file gnss_signal.h
3  * \brief Implementation of the Gnss_Signal class
4  * \author
5  * Luis Esteve, 2012. luis(at)epsilon-formacion.com
6  * Javier Arribas, 2012. jarribas(at)cttc.es
7  *
8  * -----------------------------------------------------------------------------
9  *
10  * GNSS-SDR is a Global Navigation Satellite System software-defined receiver.
11  * This file is part of GNSS-SDR.
12  *
13  * Copyright (C) 2010-2020 (see AUTHORS file for a list of contributors)
14  * SPDX-License-Identifier: GPL-3.0-or-later
15  *
16  * -----------------------------------------------------------------------------
17  */
18 
19 #ifndef GNSS_SDR_GNSS_SIGNAL_H
20 #define GNSS_SDR_GNSS_SIGNAL_H
21 
22 #include "gnss_satellite.h"
23 #include <ostream>
24 #include <string>
25 
26 /** \addtogroup Core
27  * \{ */
28 /** \addtogroup System_Parameters
29  * \{ */
30 
31 
32 /*!
33  * \brief This class represents a GNSS signal.
34  *
35  * It contains information about the space vehicle and the specific signal.
36  */
38 {
39 public:
40  Gnss_Signal() = default;
41  explicit Gnss_Signal(const std::string& signal_);
42  Gnss_Signal(const Gnss_Satellite& satellite_, const std::string& signal_);
43  ~Gnss_Signal() = default;
44  std::string get_signal_str() const; //!< Get the satellite signal {"1C" for GPS L1 C/A, "2S" for GPS L2C (M), "L5" for GPS L5, "1G" for GLONASS L1 C/A, "1B" for Galileo E1B, "5X" for Galileo E5a.
45  Gnss_Satellite get_satellite() const; //!< Get the Gnss_Satellite associated to the signal
46 
47  friend bool operator==(const Gnss_Signal& /*sig1*/, const Gnss_Signal& /*sig2*/); //!< operator== for comparison
48  friend std::ostream& operator<<(std::ostream& /*out*/, const Gnss_Signal& /*sig*/); //!< operator<< for pretty printing
49 
50 private:
51  Gnss_Satellite satellite{};
52  std::string signal{};
53 };
54 
55 
56 /** \} */
57 /** \} */
58 #endif // GNSS_SDR_GNSS_SIGNAL_H
std::string get_signal_str() const
Get the satellite signal {"1C" for GPS L1 C/A, "2S" for GPS L2C (M), "L5" for GPS L5...
Interface of the Gnss_Satellite class.
This class represents a GNSS satellite.
Gnss_Satellite get_satellite() const
Get the Gnss_Satellite associated to the signal.
friend std::ostream & operator<<(std::ostream &, const Gnss_Signal &)
operator<< for pretty printing
This class represents a GNSS signal.
Definition: gnss_signal.h:37
friend bool operator==(const Gnss_Signal &, const Gnss_Signal &)
operator== for comparison