Base class for ***StatsCalculator classes. More...
#include "lte-stats-calculator.h"
Public Member Functions | |
LteStatsCalculator () | |
Constructor. More... | |
~LteStatsCalculator () override | |
Destructor. More... | |
bool | ExistsCellIdPath (std::string path) |
Checks if there is an already stored cell id for the given path. More... | |
bool | ExistsImsiPath (std::string path) |
Checks if there is an already stored IMSI for the given path. More... | |
uint16_t | GetCellIdPath (std::string path) |
Retrieves the cell id information for the given path. More... | |
std::string | GetDlOutputFilename () |
Get the name of the file where the downlink statistics will be stored. More... | |
uint64_t | GetImsiPath (std::string path) |
Retrieves the imsi information for the given path. More... | |
std::string | GetUlOutputFilename () |
Get the name of the file where the uplink statistics will be stored. More... | |
void | SetCellIdPath (std::string path, uint16_t cellId) |
Stores the (path, cellId) pairs in a map. More... | |
void | SetDlOutputFilename (std::string outputFilename) |
Set the name of the file where the downlink statistics will be stored. More... | |
void | SetImsiPath (std::string path, uint64_t imsi) |
Stores the (path, imsi) pairs in a map. More... | |
void | SetUlOutputFilename (std::string outputFilename) |
Set the name of the file where the uplink statistics will be stored. More... | |
Public Member Functions inherited from ns3::Object | |
Object () | |
Constructor. More... | |
~Object () override | |
Destructor. More... | |
void | AggregateObject (Ptr< Object > other) |
Aggregate two Objects together. More... | |
void | Dispose () |
Dispose of this Object. More... | |
AggregateIterator | GetAggregateIterator () const |
Get an iterator to the Objects aggregated to this one. More... | |
TypeId | GetInstanceTypeId () const override |
Get the most derived TypeId for this Object. More... | |
template<typename T > | |
Ptr< T > | GetObject () const |
Get a pointer to the requested aggregated Object. More... | |
template<> | |
Ptr< Object > | GetObject () const |
Specialization of () for objects of type ns3::Object. More... | |
template<typename T > | |
Ptr< T > | GetObject (TypeId tid) const |
Get a pointer to the requested aggregated Object by TypeId. More... | |
template<> | |
Ptr< Object > | GetObject (TypeId tid) const |
Specialization of (TypeId tid) for objects of type ns3::Object. More... | |
void | Initialize () |
Invoke DoInitialize on all Objects aggregated to this one. More... | |
bool | IsInitialized () const |
Check if the object has been initialized. More... | |
Public Member Functions inherited from ns3::SimpleRefCount< Object, ObjectBase, ObjectDeleter > | |
SimpleRefCount () | |
Default constructor. More... | |
SimpleRefCount (const SimpleRefCount &o[[maybe_unused]]) | |
Copy constructor. More... | |
uint32_t | GetReferenceCount () const |
Get the reference count of the object. More... | |
SimpleRefCount & | operator= (const SimpleRefCount &o[[maybe_unused]]) |
Assignment operator. More... | |
void | Ref () const |
Increment the reference count. More... | |
void | Unref () const |
Decrement the reference count. More... | |
Public Member Functions inherited from ns3::ObjectBase | |
virtual | ~ObjectBase () |
Virtual destructor. More... | |
void | GetAttribute (std::string name, AttributeValue &value) const |
Get the value of an attribute, raising fatal errors if unsuccessful. More... | |
bool | GetAttributeFailSafe (std::string name, AttributeValue &value) const |
Get the value of an attribute without raising errors. More... | |
void | SetAttribute (std::string name, const AttributeValue &value) |
Set a single attribute, raising fatal errors if unsuccessful. More... | |
bool | SetAttributeFailSafe (std::string name, const AttributeValue &value) |
Set a single attribute without raising errors. More... | |
bool | TraceConnect (std::string name, std::string context, const CallbackBase &cb) |
Connect a TraceSource to a Callback with a context. More... | |
bool | TraceConnectWithoutContext (std::string name, const CallbackBase &cb) |
Connect a TraceSource to a Callback without a context. More... | |
bool | TraceDisconnect (std::string name, std::string context, const CallbackBase &cb) |
Disconnect from a TraceSource a Callback previously connected with a context. More... | |
bool | TraceDisconnectWithoutContext (std::string name, const CallbackBase &cb) |
Disconnect from a TraceSource a Callback previously connected without a context. More... | |
Static Public Member Functions | |
static TypeId | GetTypeId () |
Register this type. More... | |
Static Public Member Functions inherited from ns3::Object | |
static TypeId | GetTypeId () |
Register this type. More... | |
Static Public Member Functions inherited from ns3::ObjectBase | |
static TypeId | GetTypeId () |
Get the type ID. More... | |
Static Protected Member Functions | |
static uint16_t | FindCellIdFromEnbMac (std::string path, uint16_t rnti) |
Retrieves CellId from Enb MAC path in the attribute system. More... | |
static uint16_t | FindCellIdFromEnbRlcPath (std::string path) |
Retrieves CellId from Enb RLC path in the attribute system. More... | |
static uint64_t | FindImsiForEnb (std::string path, uint16_t rnti) |
Retrieves IMSI from path for Enb in the attribute system. More... | |
static uint64_t | FindImsiForUe (std::string path, uint16_t rnti) |
Retrieves IMSI from path for Ue in the attribute system. More... | |
static uint64_t | FindImsiFromEnbMac (std::string path, uint16_t rnti) |
Retrieves IMSI from Enb MAC path in the attribute system. More... | |
static uint64_t | FindImsiFromEnbRlcPath (std::string path) |
Retrieves IMSI from Enb RLC path in the attribute system. More... | |
static uint64_t | FindImsiFromLteNetDevice (std::string path) |
Retrieves IMSI from LteNetDevice path in the attribute system. More... | |
static uint64_t | FindImsiFromUePhy (std::string path) |
Retrieves IMSI from Ue PHY path in the attribute system. More... | |
Private Attributes | |
std::string | m_dlOutputFilename |
Name of the file where the downlink results will be saved. More... | |
std::map< std::string, uint16_t > | m_pathCellIdMap |
List of CellId by path in the attribute system. More... | |
std::map< std::string, uint64_t > | m_pathImsiMap |
List of IMSI by path in the attribute system. More... | |
std::string | m_ulOutputFilename |
Name of the file where the uplink results will be saved. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from ns3::Object | |
Object (const Object &o) | |
Copy an Object. More... | |
virtual void | DoDispose () |
Destructor implementation. More... | |
virtual void | DoInitialize () |
Initialize() implementation. More... | |
virtual void | NotifyNewAggregate () |
Notify all Objects aggregated to this one of a new Object being aggregated. More... | |
Protected Member Functions inherited from ns3::ObjectBase | |
void | ConstructSelf (const AttributeConstructionList &attributes) |
Complete construction of ObjectBase; invoked by derived classes. More... | |
virtual void | NotifyConstructionCompleted () |
Notifier called once the ObjectBase is fully constructed. More... | |
Related Functions inherited from ns3::ObjectBase | |
static TypeId | GetObjectIid () |
Ensure the TypeId for ObjectBase gets fully configured to anchor the inheritance tree properly. More... | |
Base class for ***StatsCalculator classes.
Provides basic functionality to parse and store IMSI and CellId. Also stores names of output files.
Definition at line 39 of file lte-stats-calculator.h.
ns3::LteStatsCalculator::LteStatsCalculator | ( | ) |
Constructor.
Definition at line 36 of file lte-stats-calculator.cc.
|
override |
Destructor.
Definition at line 43 of file lte-stats-calculator.cc.
bool ns3::LteStatsCalculator::ExistsCellIdPath | ( | std::string | path | ) |
Checks if there is an already stored cell id for the given path.
path | Path in the attribute system to check |
Definition at line 102 of file lte-stats-calculator.cc.
References m_pathCellIdMap.
bool ns3::LteStatsCalculator::ExistsImsiPath | ( | std::string | path | ) |
Checks if there is an already stored IMSI for the given path.
path | Path in the attribute system to check |
Definition at line 83 of file lte-stats-calculator.cc.
References m_pathImsiMap.
|
staticprotected |
Retrieves CellId from Enb MAC path in the attribute system.
path | Path in the attribute system to get |
rnti | RNTI of UE for which CellId is needed |
Definition at line 233 of file lte-stats-calculator.cc.
References FindCellIdFromEnbRlcPath(), NS_LOG_FUNCTION, and NS_LOG_LOGIC.
|
staticprotected |
Retrieves CellId from Enb RLC path in the attribute system.
path | Path in the attribute system to get |
Definition at line 194 of file lte-stats-calculator.cc.
References ns3::Config::MatchContainer::Get(), ns3::LteEnbNetDevice::GetCellId(), ns3::Config::MatchContainer::GetN(), ns3::Object::GetObject(), ns3::Config::LookupMatches(), NS_FATAL_ERROR, NS_LOG_FUNCTION, and NS_LOG_LOGIC.
Referenced by ns3::MacStatsCalculator::DlSchedulingCallback(), FindCellIdFromEnbMac(), and ns3::MacStatsCalculator::UlSchedulingCallback().
|
staticprotected |
Retrieves IMSI from path for Enb in the attribute system.
path | Path in the attribute system to get |
rnti | RNTI of UE for which IMSI is needed |
Definition at line 247 of file lte-stats-calculator.cc.
References FindImsiFromEnbRlcPath(), FindImsiFromLteNetDevice(), NS_LOG_FUNCTION, and NS_LOG_LOGIC.
|
staticprotected |
Retrieves IMSI from path for Ue in the attribute system.
path | Path in the attribute system to get |
rnti | RNTI of UE for which IMSI is needed |
Definition at line 271 of file lte-stats-calculator.cc.
References FindImsiFromEnbRlcPath(), FindImsiFromLteNetDevice(), NS_LOG_FUNCTION, and NS_LOG_LOGIC.
|
staticprotected |
Retrieves IMSI from Enb MAC path in the attribute system.
path | Path in the attribute system to get |
rnti | RNTI of UE for which IMSI is needed |
Definition at line 218 of file lte-stats-calculator.cc.
References FindImsiFromEnbRlcPath(), NS_LOG_FUNCTION, and NS_LOG_LOGIC.
Referenced by ns3::PhyStatsCalculator::ReportUeSinr().
|
staticprotected |
Retrieves IMSI from Enb RLC path in the attribute system.
path | Path in the attribute system to get |
Definition at line 121 of file lte-stats-calculator.cc.
References ns3::Config::MatchContainer::Get(), ns3::UeManager::GetImsi(), ns3::Config::MatchContainer::GetN(), ns3::Object::GetObject(), ns3::Config::LookupMatches(), NS_FATAL_ERROR, NS_LOG_FUNCTION, and NS_LOG_LOGIC.
Referenced by ns3::PhyTxStatsCalculator::DlPhyTransmissionCallback(), ns3::MacStatsCalculator::DlSchedulingCallback(), FindImsiForEnb(), FindImsiForUe(), FindImsiFromEnbMac(), ns3::PhyRxStatsCalculator::UlPhyReceptionCallback(), and ns3::MacStatsCalculator::UlSchedulingCallback().
|
staticprotected |
Retrieves IMSI from LteNetDevice path in the attribute system.
path | Path in the attribute system to get |
Definition at line 170 of file lte-stats-calculator.cc.
References ns3::Config::MatchContainer::Get(), ns3::LteUeNetDevice::GetImsi(), ns3::Config::MatchContainer::GetN(), ns3::Object::GetObject(), ns3::Config::LookupMatches(), NS_FATAL_ERROR, NS_LOG_FUNCTION, and NS_LOG_LOGIC.
Referenced by ns3::PhyRxStatsCalculator::DlPhyReceptionCallback(), FindImsiForEnb(), FindImsiForUe(), ns3::PhyStatsCalculator::ReportCurrentCellRsrpSinrCallback(), and ns3::PhyTxStatsCalculator::UlPhyTransmissionCallback().
|
staticprotected |
Retrieves IMSI from Ue PHY path in the attribute system.
path | Path in the attribute system to get |
Definition at line 146 of file lte-stats-calculator.cc.
References ns3::Config::MatchContainer::Get(), ns3::Config::MatchContainer::GetN(), ns3::Object::GetObject(), ns3::Config::LookupMatches(), NS_FATAL_ERROR, and NS_LOG_FUNCTION.
uint16_t ns3::LteStatsCalculator::GetCellIdPath | ( | std::string | path | ) |
Retrieves the cell id information for the given path.
path | Path in the attribute system to get |
Definition at line 115 of file lte-stats-calculator.cc.
References m_pathCellIdMap.
std::string ns3::LteStatsCalculator::GetDlOutputFilename | ( | ) |
Get the name of the file where the downlink statistics will be stored.
Definition at line 77 of file lte-stats-calculator.cc.
References m_dlOutputFilename.
Referenced by ns3::PhyTxStatsCalculator::DlPhyTransmission(), ns3::MacStatsCalculator::GetDlOutputFilename(), ns3::RadioBearerStatsCalculator::GetDlOutputFilename(), ns3::PhyRxStatsCalculator::GetDlRxOutputFilename(), and ns3::PhyTxStatsCalculator::GetDlTxOutputFilename().
uint64_t ns3::LteStatsCalculator::GetImsiPath | ( | std::string | path | ) |
Retrieves the imsi information for the given path.
path | Path in the attribute system to get |
Definition at line 96 of file lte-stats-calculator.cc.
References m_pathImsiMap.
|
static |
Register this type.
Definition at line 49 of file lte-stats-calculator.cc.
References ns3::TypeId::SetParent().
std::string ns3::LteStatsCalculator::GetUlOutputFilename | ( | ) |
Get the name of the file where the uplink statistics will be stored.
Definition at line 65 of file lte-stats-calculator.cc.
References m_ulOutputFilename.
Referenced by ns3::MacStatsCalculator::GetUlOutputFilename(), ns3::RadioBearerStatsCalculator::GetUlOutputFilename(), ns3::PhyRxStatsCalculator::GetUlRxOutputFilename(), and ns3::PhyTxStatsCalculator::GetUlTxOutputFilename().
void ns3::LteStatsCalculator::SetCellIdPath | ( | std::string | path, |
uint16_t | cellId | ||
) |
Stores the (path, cellId) pairs in a map.
path | Path in the attribute system to store |
cellId | cell id value to store |
Definition at line 108 of file lte-stats-calculator.cc.
References m_pathCellIdMap, and NS_LOG_FUNCTION.
void ns3::LteStatsCalculator::SetDlOutputFilename | ( | std::string | outputFilename | ) |
Set the name of the file where the downlink statistics will be stored.
outputFilename | string with the name of the file |
Definition at line 71 of file lte-stats-calculator.cc.
References m_dlOutputFilename.
Referenced by ns3::RadioBearerStatsCalculator::GetTypeId(), ns3::MacStatsCalculator::SetDlOutputFilename(), ns3::PhyRxStatsCalculator::SetDlRxOutputFilename(), and ns3::PhyTxStatsCalculator::SetDlTxOutputFilename().
void ns3::LteStatsCalculator::SetImsiPath | ( | std::string | path, |
uint64_t | imsi | ||
) |
Stores the (path, imsi) pairs in a map.
path | Path in the attribute system to store |
imsi | IMSI value to store |
Definition at line 89 of file lte-stats-calculator.cc.
References m_pathImsiMap, and NS_LOG_FUNCTION.
void ns3::LteStatsCalculator::SetUlOutputFilename | ( | std::string | outputFilename | ) |
Set the name of the file where the uplink statistics will be stored.
outputFilename | string with the name of the file |
Definition at line 59 of file lte-stats-calculator.cc.
References m_ulOutputFilename.
Referenced by ns3::RadioBearerStatsCalculator::GetTypeId(), ns3::MacStatsCalculator::SetUlOutputFilename(), ns3::PhyRxStatsCalculator::SetUlRxOutputFilename(), and ns3::PhyTxStatsCalculator::SetUlTxOutputFilename().
|
private |
Name of the file where the downlink results will be saved.
Definition at line 201 of file lte-stats-calculator.h.
Referenced by GetDlOutputFilename(), and SetDlOutputFilename().
|
private |
List of CellId by path in the attribute system.
Definition at line 196 of file lte-stats-calculator.h.
Referenced by ExistsCellIdPath(), GetCellIdPath(), and SetCellIdPath().
|
private |
List of IMSI by path in the attribute system.
Definition at line 191 of file lte-stats-calculator.h.
Referenced by ExistsImsiPath(), GetImsiPath(), and SetImsiPath().
|
private |
Name of the file where the uplink results will be saved.
Definition at line 206 of file lte-stats-calculator.h.
Referenced by GetUlOutputFilename(), and SetUlOutputFilename().