1   /* Copyright 2002-2021 CS GROUP
2    * Licensed to CS GROUP (CS) under one or more
3    * contributor license agreements.  See the NOTICE file distributed with
4    * this work for additional information regarding copyright ownership.
5    * CS licenses this file to You under the Apache License, Version 2.0
6    * (the "License"); you may not use this file except in compliance with
7    * the License.  You may obtain a copy of the License at
8    *
9    *   http://www.apache.org/licenses/LICENSE-2.0
10   *
11   * Unless required by applicable law or agreed to in writing, software
12   * distributed under the License is distributed on an "AS IS" BASIS,
13   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14   * See the License for the specific language governing permissions and
15   * limitations under the License.
16   */
17  package org.orekit.propagation.analytical.gnss.data;
18  
19  /**
20   * Container for data contained in a BeiDou navigation message.
21   * @author Bryan Cazabonne
22   * @since 11.0
23   */
24  public class BeidouNavigationMessage extends AbstractNavigationMessage implements GNSSOrbitalElements {
25  
26      /** Age of Data, Ephemeris. */
27      private int aode;
28  
29      /** Age of Data, Clock. */
30      private int aodc;
31  
32      /** B1/B3 Group Delay Differential (s). */
33      private double tgd1;
34  
35      /** B2/B3 Group Delay Differential (s). */
36      private double tgd2;
37  
38      /** The user SV accuracy (m). */
39      private double svAccuracy;
40  
41      /** Constructor. */
42      public BeidouNavigationMessage() {
43          super(GNSSConstants.BEIDOU_MU, GNSSConstants.BEIDOU_AV, GNSSConstants.BEIDOU_WEEK_NB);
44      }
45  
46      /**
47       * Getter for the Age Of Data Clock (AODC).
48       * @return the Age Of Data Clock (AODC)
49       */
50      public int getAODC() {
51          return aodc;
52      }
53  
54      /**
55       * Setter for the age of data clock.
56       * @param aod the age of data to set
57       */
58      public void setAODC(final double aod) {
59          // The value is given as a floating number in the navigation message
60          this.aodc = (int) aod;
61      }
62  
63      /**
64       * Getter for the Age Of Data Ephemeris (AODE).
65       * @return the Age Of Data Ephemeris (AODE)
66       */
67      public int getAODE() {
68          return aode;
69      }
70  
71      /**
72       * Setter for the age of data ephemeric.
73       * @param aod the age of data to set
74       */
75      public void setAODE(final double aod) {
76          // The value is given as a floating number in the navigation message
77          this.aode = (int) aod;
78      }
79  
80      /**
81       * Getter for the estimated group delay differential TGD1 for B1I signal.
82       * @return the estimated group delay differential TGD1 for B1I signal (s)
83       */
84      public double getTGD1() {
85          return tgd1;
86      }
87  
88      /**
89       * Setter for the B1/B3 Group Delay Differential (s).
90       * @param tgd the group delay differential to set
91       */
92      public void setTGD1(final double tgd) {
93          this.tgd1 = tgd;
94      }
95  
96      /**
97       * Getter for the estimated group delay differential TGD for B2I signal.
98       * @return the estimated group delay differential TGD2 for B2I signal (s)
99       */
100     public double getTGD2() {
101         return tgd2;
102     }
103 
104     /**
105      * Setter for the B2/B3 Group Delay Differential (s).
106      * @param tgd the group delay differential to set
107      */
108     public void setTGD2(final double tgd) {
109         this.tgd2 = tgd;
110     }
111 
112     /**
113      * Getter for the user SV accuray (meters).
114      * @return the user SV accuracy
115      */
116     public double getSvAccuracy() {
117         return svAccuracy;
118     }
119 
120     /**
121      * Setter for the user SV accuracy.
122      * @param svAccuracy the value to set
123      */
124     public void setSvAccuracy(final double svAccuracy) {
125         this.svAccuracy = svAccuracy;
126     }
127 
128 }