A Discrete-Event Network Simulator
API
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
lte-stats-calculator.h
Go to the documentation of this file.
1 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2011 Centre Tecnologic de Telecomunicacions de Catalunya (CTTC)
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: Jaume Nin <jnin@cttc.es>
19  */
20 
21 #ifndef LTE_STATS_CALCULATOR_H_
22 #define LTE_STATS_CALCULATOR_H_
23 
24 #include "ns3/object.h"
25 #include "ns3/string.h"
26 #include <map>
27 
28 namespace ns3 {
29 
30 class LteStatsCalculator : public Object
31 {
32 public:
37 
41  virtual ~LteStatsCalculator ();
42 
43  static TypeId GetTypeId (void);
44 
50  void SetUlOutputFilename (std::string outputFilename);
51 
56  std::string GetUlOutputFilename (void);
57 
63  void SetDlOutputFilename (std::string outputFilename);
64 
69  std::string GetDlOutputFilename (void);
70 
76  bool ExistsImsiPath (std::string path);
77 
83  void SetImsiPath (std::string path, uint64_t imsi);
84 
90  uint64_t GetImsiPath (std::string path);
91 
97  bool ExistsCellIdPath (std::string path);
98 
104  void SetCellIdPath (std::string path, uint16_t cellId);
105 
111  uint16_t GetCellIdPath (std::string path);
112 
113 protected:
114 
115  static uint64_t FindImsiFromEnbRlcPath (std::string path);
116  static uint64_t FindImsiFromUePhy (std::string path);
117  static uint64_t FindImsiFromLteNetDevice (std::string path);
118  static uint16_t FindCellIdFromEnbRlcPath (std::string path);
119  static uint64_t FindImsiFromEnbMac (std::string path, uint16_t rnti);
120  static uint16_t FindCellIdFromEnbMac (std::string path, uint16_t rnti);
121  static uint64_t FindImsiForEnb (std::string path, uint16_t rnti);
122  static uint64_t FindImsiForUe (std::string path, uint16_t rnti);
123 
124 private:
125 
126  std::map<std::string, uint64_t> m_pathImsiMap;
127  std::map<std::string, uint16_t> m_pathCellIdMap;
128 
129  std::string m_dlOutputFilename;
130  std::string m_ulOutputFilename;
131 };
132 
133 } // namespace ns3
134 
135 #endif /* LTE_STATS_CALCULATOR_H_ */
Doxygen introspection did not find any typical Config paths.
static uint64_t FindImsiFromLteNetDevice(std::string path)
static uint64_t FindImsiFromUePhy(std::string path)
static uint64_t FindImsiFromEnbMac(std::string path, uint16_t rnti)
void SetCellIdPath(std::string path, uint16_t cellId)
Stores the (path, cellId) pairs in a map.
static uint16_t FindCellIdFromEnbRlcPath(std::string path)
static TypeId GetTypeId(void)
static uint16_t FindCellIdFromEnbMac(std::string path, uint16_t rnti)
std::map< std::string, uint64_t > m_pathImsiMap
void SetUlOutputFilename(std::string outputFilename)
Set the name of the file where the uplink statistics will be stored.
static uint64_t FindImsiForEnb(std::string path, uint16_t rnti)
std::string GetUlOutputFilename(void)
Get the name of the file where the uplink statistics will be stored.
bool ExistsCellIdPath(std::string path)
Checks if there is an already stored cell id for the given path.
void SetDlOutputFilename(std::string outputFilename)
Set the name of the file where the downlink statistics will be stored.
static uint64_t FindImsiFromEnbRlcPath(std::string path)
static uint64_t FindImsiForUe(std::string path, uint16_t rnti)
uint16_t GetCellIdPath(std::string path)
Retrieves the cell id information for the given path.
uint64_t GetImsiPath(std::string path)
Retrieves the imsi information for the given path.
std::map< std::string, uint16_t > m_pathCellIdMap
virtual ~LteStatsCalculator()
Destructor.
void SetImsiPath(std::string path, uint64_t imsi)
Stores the (path, imsi) pairs in a map.
a base class which provides memory management and object aggregation
Definition: object.h:64
a unique identifier for an interface.
Definition: type-id.h:49
bool ExistsImsiPath(std::string path)
Checks if there is an already stored IMSI for the given path.
std::string GetDlOutputFilename(void)
Get the name of the file where the downlink statistics will be stored.