#include <data-calculator.h>
Public Member Functions | |
DataCalculator () | |
virtual | ~DataCalculator () |
bool | GetEnabled () const |
void | Enable () |
void | Disable () |
void | SetKey (const std::string key) |
std::string | GetKey () const |
virtual void | Start (const Time &startTime) |
virtual void | Stop (const Time &stopTime) |
virtual void | Output (DataOutputCallback &callback) const =0 |
Protected Member Functions | |
virtual void | DoDispose (void) |
Protected Attributes | |
bool | m_enabled |
std::string | m_key |
Private Attributes | |
EventId | m_startEvent |
EventId | m_stopEvent |
Definition at line 34 of file data-calculator.h.
DataCalculator::DataCalculator | ( | ) |
Definition at line 33 of file data-calculator.cc.
References NS_LOG_FUNCTION_NOARGS.
DataCalculator::~DataCalculator | ( | ) | [virtual] |
Definition at line 39 of file data-calculator.cc.
References NS_LOG_FUNCTION_NOARGS.
void DataCalculator::Disable | ( | void | ) |
void DataCalculator::DoDispose | ( | void | ) | [protected, virtual] |
This method is called by Object::Dispose or by the object's destructor, whichever comes first.
Subclasses are expected to implement their real destruction code in an overriden version of this method and chain up to their parent's implementation once they are done. i.e., for simplicity, the destructor of every subclass should be empty and its content should be moved to the associated DoDispose method.
Reimplemented from ns3::Object.
Reimplemented in ns3::MinMaxAvgTotalCalculator< T >, ns3::CounterCalculator< T >, ns3::PacketCounterCalculator, ns3::PacketSizeMinMaxAvgTotalCalculator, ns3::TimeMinMaxAvgTotalCalculator, ns3::MinMaxAvgTotalCalculator< uint32_t >, and ns3::CounterCalculator< uint32_t >.
Definition at line 45 of file data-calculator.cc.
References ns3::Simulator::Cancel(), m_startEvent, m_stopEvent, and NS_LOG_FUNCTION_NOARGS.
void DataCalculator::Enable | ( | void | ) |
bool DataCalculator::GetEnabled | ( | ) | const |
Definition at line 87 of file data-calculator.cc.
References m_enabled.
std::string DataCalculator::GetKey | ( | ) | const |
Definition at line 65 of file data-calculator.cc.
References m_key.
virtual void ns3::DataCalculator::Output | ( | DataOutputCallback & | callback | ) | const [pure virtual] |
void DataCalculator::SetKey | ( | const std::string | key | ) |
Definition at line 58 of file data-calculator.cc.
References m_key.
void DataCalculator::Start | ( | const Time & | startTime | ) | [virtual] |
Definition at line 95 of file data-calculator.cc.
References Enable(), m_startEvent, and ns3::Simulator::Schedule().
void DataCalculator::Stop | ( | const Time & | stopTime | ) | [virtual] |
Definition at line 105 of file data-calculator.cc.
References Disable(), m_stopEvent, and ns3::Simulator::Schedule().
bool ns3::DataCalculator::m_enabled [protected] |
Definition at line 52 of file data-calculator.h.
Referenced by Disable(), Enable(), GetEnabled(), ns3::TimeMinMaxAvgTotalCalculator::Update(), ns3::CounterCalculator< T >::Update(), and ns3::MinMaxAvgTotalCalculator< T >::Update().
std::string ns3::DataCalculator::m_key [protected] |
Definition at line 54 of file data-calculator.h.
Referenced by GetKey(), ns3::TimeMinMaxAvgTotalCalculator::Output(), ns3::CounterCalculator< T >::Output(), ns3::MinMaxAvgTotalCalculator< T >::Output(), and SetKey().
EventId ns3::DataCalculator::m_startEvent [private] |
Definition at line 59 of file data-calculator.h.
Referenced by DoDispose(), and Start().
EventId ns3::DataCalculator::m_stopEvent [private] |
Definition at line 60 of file data-calculator.h.
Referenced by DoDispose(), and Stop().