satellite-stats-link-modcod-helper.h
Go to the documentation of this file.
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2014 Magister Solutions
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License version 2 as
7  * published by the Free Software Foundation;
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program; if not, write to the Free Software
16  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17  *
18  * Author: Bastien Tauran <bastien.tauran@viveris.fr>
19  *
20  */
21 
22 #ifndef SATELLITE_STATS_LINK_MODCOD_HELPER_H
23 #define SATELLITE_STATS_LINK_MODCOD_HELPER_H
24 
25 #include "satellite-stats-helper.h"
26 
27 #include <ns3/address.h>
28 #include <ns3/collector-map.h>
29 #include <ns3/ptr.h>
30 
31 #include <list>
32 #include <map>
33 
34 namespace ns3
35 {
36 
37 // BASE CLASS /////////////////////////////////////////////////////////////////
38 
39 class SatHelper;
40 class Node;
41 class Time;
42 class DataCollectionObject;
43 class DistributionCollector;
44 
50 {
51  public:
52  // inherited from SatStatsHelper base class
53  SatStatsLinkModcodHelper(Ptr<const SatHelper> satHelper);
54 
58  virtual ~SatStatsLinkModcodHelper();
59 
63  static TypeId GetTypeId();
64 
68  void SetAveragingMode(bool averagingMode);
69 
73  bool GetAveragingMode() const;
74 
79  void InstallProbes();
80 
90  void RxLinkModcodCallback(uint32_t modcod, const Address& from);
91 
92  protected:
93  // inherited from SatStatsHelper base class
94  void DoInstall();
95 
99  virtual void DoInstallProbes() = 0;
100 
106  bool ConnectProbeToCollector(Ptr<Probe> probe, uint32_t identifier);
107 
114  void PassSampleToCollector(uint32_t modcod, uint32_t identifier);
115 
117  CollectorMap m_terminalCollectors;
118 
120  Ptr<DistributionCollector> m_averagingCollector;
121 
123  Ptr<DataCollectionObject> m_aggregator;
124 
125  private:
127 
128 }; // end of class SatStatsLinkModcodHelper
129 
130 // FORWARD FEEDER LINK /////////////////////////////////////////////////////
131 
150 {
151  public:
152  // inherited from SatStatsHelper base class
153  SatStatsFwdFeederLinkModcodHelper(Ptr<const SatHelper> satHelper);
154 
159 
163  static TypeId GetTypeId();
164 
165  protected:
166  // inherited from SatStatsLinkModcodHelper base class
167  void DoInstallProbes();
168 
169 }; // end of class SatStatsFwdFeederLinkModcodHelper
170 
171 // FORWARD USER LINK /////////////////////////////////////////////////////
172 
191 {
192  public:
193  // inherited from SatStatsHelper base class
194  SatStatsFwdUserLinkModcodHelper(Ptr<const SatHelper> satHelper);
195 
200 
204  static TypeId GetTypeId();
205 
206  protected:
207  // inherited from SatStatsLinkModcodHelper base class
208  void DoInstallProbes();
209 
210 }; // end of class SatStatsFwdUserLinkModcodHelper
211 
212 // RETURN FEEDER LINK //////////////////////////////////////////////
213 
232 {
233  public:
234  // inherited from SatStatsHelper base class
235  SatStatsRtnFeederLinkModcodHelper(Ptr<const SatHelper> satHelper);
236 
241 
245  static TypeId GetTypeId();
246 
247  protected:
248  // inherited from SatStatsLinkModcodHelper base class
249  void DoInstallProbes();
250 
251 }; // end of class SatStatsRtnFeederLinkModcodHelper
252 
253 // RETURN USER LINK //////////////////////////////////////////////
254 
273 {
274  public:
275  // inherited from SatStatsHelper base class
276  SatStatsRtnUserLinkModcodHelper(Ptr<const SatHelper> satHelper);
277 
282 
286  static TypeId GetTypeId();
287 
288  protected:
289  // inherited from SatStatsLinkModcodHelper base class
290  void DoInstallProbes();
291 
292 }; // end of class SatStatsRtnUserLinkModcodHelper
293 
294 } // end of namespace ns3
295 
296 #endif /* SATELLITE_STATS_LINK_MODCOD_HELPER_H */
Parent abstract class of all satellite statistics helpers.
SatArqSequenceNumber is handling the sequence numbers for the ARQ process.