core
lib
GNSSCore
CarrierBand.cpp
Go to the documentation of this file.
1
8
//==============================================================================
9
//
10
// This file is part of GNSSTk, the ARL:UT GNSS Toolkit.
11
//
12
// The GNSSTk is free software; you can redistribute it and/or modify
13
// it under the terms of the GNU Lesser General Public License as published
14
// by the Free Software Foundation; either version 3.0 of the License, or
15
// any later version.
16
//
17
// The GNSSTk is distributed in the hope that it will be useful,
18
// but WITHOUT ANY WARRANTY; without even the implied warranty of
19
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20
// GNU Lesser General Public License for more details.
21
//
22
// You should have received a copy of the GNU Lesser General Public
23
// License along with GNSSTk; if not, write to the Free Software Foundation,
24
// Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
25
//
26
// This software was developed by Applied Research Laboratories at the
27
// University of Texas at Austin.
28
// Copyright 2004-2022, The Board of Regents of The University of Texas System
29
//
30
//==============================================================================
31
32
//==============================================================================
33
//
34
// This software was developed by Applied Research Laboratories at the
35
// University of Texas at Austin, under contract to an agency or agencies
36
// within the U.S. Department of Defense. The U.S. Government retains all
37
// rights to use, duplicate, distribute, disclose, or release this software.
38
//
39
// Pursuant to DoD Directive 523024
40
//
41
// DISTRIBUTION STATEMENT A: This software has been approved for public
42
// release, distribution is unlimited.
43
//
44
//==============================================================================
45
46
#include "
CarrierBand.hpp
"
47
48
namespace
gnsstk
49
{
50
namespace
StringUtils
51
{
52
std::string
asString
(
CarrierBand
e) noexcept
53
{
54
switch
(e)
55
{
56
case
CarrierBand::Unknown
:
return
"Unknown"
;
57
case
CarrierBand::Any
:
return
"Any"
;
58
case
CarrierBand::L1L2
:
return
"L1L2"
;
59
case
CarrierBand::L1
:
return
"L1"
;
60
case
CarrierBand::L2
:
return
"L2"
;
61
case
CarrierBand::L5
:
return
"L5"
;
62
case
CarrierBand::G1
:
return
"G1"
;
63
case
CarrierBand::G1a
:
return
"G1a"
;
64
case
CarrierBand::G2a
:
return
"G2a"
;
65
case
CarrierBand::G2
:
return
"G2"
;
66
case
CarrierBand::G3
:
return
"G3"
;
67
case
CarrierBand::E5b
:
return
"E5b"
;
68
case
CarrierBand::E5ab
:
return
"E5ab"
;
69
case
CarrierBand::E6
:
return
"E6"
;
70
case
CarrierBand::B1
:
return
"B1"
;
71
case
CarrierBand::B2
:
return
"B2"
;
72
case
CarrierBand::B3
:
return
"B3"
;
73
case
CarrierBand::I9
:
return
"I9"
;
74
case
CarrierBand::Undefined
:
return
"Undefined"
;
75
default
:
return
"???"
;
76
}
// switch (e)
77
}
// asString(CarrierBand)
78
79
80
CarrierBand
asCarrierBand
(
const
std::string& s) noexcept
81
{
82
if
(s ==
"Unknown"
)
83
return
CarrierBand::Unknown
;
84
if
(s ==
"Any"
)
85
return
CarrierBand::Any
;
86
if
(s ==
"L1L2"
)
87
return
CarrierBand::L1L2
;
88
if
(s ==
"L1"
)
89
return
CarrierBand::L1
;
90
if
(s ==
"L2"
)
91
return
CarrierBand::L2
;
92
if
(s ==
"L5"
)
93
return
CarrierBand::L5
;
94
if
(s ==
"G1"
)
95
return
CarrierBand::G1
;
96
if
(s ==
"G1a"
)
97
return
CarrierBand::G1a
;
98
if
(s ==
"G2a"
)
99
return
CarrierBand::G2a
;
100
if
(s ==
"G2"
)
101
return
CarrierBand::G2
;
102
if
(s ==
"G3"
)
103
return
CarrierBand::G3
;
104
if
(s ==
"E5b"
)
105
return
CarrierBand::E5b
;
106
if
(s ==
"E5ab"
)
107
return
CarrierBand::E5ab
;
108
if
(s ==
"E6"
)
109
return
CarrierBand::E6
;
110
if
(s ==
"B1"
)
111
return
CarrierBand::B1
;
112
if
(s ==
"B2"
)
113
return
CarrierBand::B2
;
114
if
(s ==
"B3"
)
115
return
CarrierBand::B3
;
116
if
(s ==
"I9"
)
117
return
CarrierBand::I9
;
118
if
(s ==
"Undefined"
)
119
return
CarrierBand::Undefined
;
120
return
CarrierBand::Unknown
;
121
}
// asCarrierBand(string)
122
}
// namespace StringUtils
123
}
// namespace gnsstk
gnsstk::StringUtils::asCarrierBand
CarrierBand asCarrierBand(const std::string &s) noexcept
Convert a string name to an CarrierBand.
Definition:
CarrierBand.cpp:80
gnsstk::CarrierBand::G1
@ G1
GLONASS G1.
gnsstk::CarrierBand::I9
@ I9
NavIC S.
gnsstk::CarrierBand::E5b
@ E5b
Galileo E5b.
gnsstk::CarrierBand
CarrierBand
Definition:
CarrierBand.hpp:54
gnsstk::CarrierBand::Any
@ Any
Used to match any carrier band.
gnsstk::StringUtils::asString
std::string asString(IonexStoreStrategy e)
Convert a IonexStoreStrategy to a whitespace-free string name.
Definition:
IonexStoreStrategy.cpp:46
gnsstk::CarrierBand::Unknown
@ Unknown
Uninitialized value.
gnsstk
For Sinex::InputHistory.
Definition:
BasicFramework.cpp:50
gnsstk::CarrierBand::L2
@ L2
GPS L2, QZSS L2.
CarrierBand.hpp
gnsstk::CarrierBand::B3
@ B3
BeiDou B3.
gnsstk::CarrierBand::B1
@ B1
BeiDou B1.
gnsstk::CarrierBand::G3
@ G3
GLONASS G3.
gnsstk::CarrierBand::G1a
@ G1a
GLONASS G1a.
gnsstk::CarrierBand::E5ab
@ E5ab
Galileo E5, BeiDou B2.
gnsstk::CarrierBand::L1
@ L1
GPS L1, Galileo E1, SBAS L1, QZSS L1, BeiDou L1.
gnsstk::CarrierBand::G2a
@ G2a
GLONASS G2a.
gnsstk::CarrierBand::B2
@ B2
BeiDou B2b.
gnsstk::CarrierBand::Undefined
@ Undefined
Code is known to be undefined (as opposed to unknown)
gnsstk::CarrierBand::L1L2
@ L1L2
GPS L1+L2.
gnsstk::CarrierBand::E6
@ E6
Galileo E6, QZSS L6.
gnsstk::CarrierBand::L5
@ L5
GPS L5, Galileo E5a, SBAS L5, QZSS L5, BeiDou B2a, NavIC L5.
gnsstk::CarrierBand::G2
@ G2
GLONASS G2.
gnsstk
Author(s):
autogenerated on Wed Oct 25 2023 02:40:38