NDN network-layer rate tracer. More...
#include <ndn-l3-rate-tracer.hpp>
Public Member Functions | |
L3RateTracer (shared_ptr< std::ostream > os, Ptr< Node > node) | |
Trace constructor that attaches to the node using node pointer. More... | |
L3RateTracer (shared_ptr< std::ostream > os, const std::string &node) | |
Trace constructor that attaches to the node using node name. More... | |
virtual | ~L3RateTracer () |
Destructor. More... | |
virtual void | PrintHeader (std::ostream &os) const |
Print head of the trace (e.g., for post-processing) More... | |
virtual void | Print (std::ostream &os) const |
Print current trace data. More... | |
Public Member Functions inherited from ns3::ndn::L3Tracer | |
L3Tracer (Ptr< Node > node) | |
Trace constructor that attaches to the node using node pointer. More... | |
L3Tracer (const std::string &node) | |
Trace constructor that attaches to the node using node name. More... | |
virtual | ~L3Tracer () |
Destructor. More... | |
Static Public Member Functions | |
static void | InstallAll (const std::string &file, Time averagingPeriod=Seconds(0.5)) |
Helper method to install tracers on all simulation nodes. More... | |
static void | Install (const NodeContainer &nodes, const std::string &file, Time averagingPeriod=Seconds(0.5)) |
Helper method to install tracers on the selected simulation nodes. More... | |
static void | Install (Ptr< Node > node, const std::string &file, Time averagingPeriod=Seconds(0.5)) |
Helper method to install tracers on a specific simulation node. More... | |
static void | Destroy () |
Explicit request to remove all statically created tracers. More... | |
static Ptr< L3RateTracer > | Install (Ptr< Node > node, shared_ptr< std::ostream > outputStream, Time averagingPeriod=Seconds(0.5)) |
Helper method to install tracers on a specific simulation node. More... | |
Protected Member Functions | |
virtual void | OutInterests (const Interest &interest, const Face &face) |
virtual void | InInterests (const Interest &interest, const Face &face) |
virtual void | OutData (const Data &data, const Face &face) |
virtual void | InData (const Data &data, const Face &face) |
virtual void | OutNack (const lp::Nack &nack, const Face &face) |
virtual void | InNack (const lp::Nack &nack, const Face &face) |
virtual void | SatisfiedInterests (const nfd::pit::Entry &, const Face &, const Data &) |
virtual void | TimedOutInterests (const nfd::pit::Entry &) |
Protected Member Functions inherited from ns3::ndn::L3Tracer | |
void | Connect () |
Additional Inherited Members | |
Protected Attributes inherited from ns3::ndn::L3Tracer | |
std::string | m_node |
Ptr< Node > | m_nodePtr |
NDN network-layer rate tracer.
Definition at line 42 of file ndn-l3-rate-tracer.hpp.
ns3::ndn::L3RateTracer::L3RateTracer | ( | shared_ptr< std::ostream > | os, |
Ptr< Node > | node | ||
) |
Trace constructor that attaches to the node using node pointer.
os | reference to the output stream |
node | pointer to the node |
Definition at line 169 of file ndn-l3-rate-tracer.cpp.
ns3::ndn::L3RateTracer::L3RateTracer | ( | shared_ptr< std::ostream > | os, |
const std::string & | node | ||
) |
Trace constructor that attaches to the node using node name.
os | reference to the output stream |
nodeName | name of the node registered using Names::Add |
Definition at line 176 of file ndn-l3-rate-tracer.cpp.
|
virtual |
|
static |
Helper method to install tracers on all simulation nodes.
file | File to which traces will be written. If filename is -, then std::out is used |
averagingPeriod | Defines averaging period for the rate calculation, as well as how often data will be written into the trace file (default, every half second) |
Definition at line 50 of file ndn-l3-rate-tracer.cpp.
References ns3::ndn::g_tracers, and Install().
|
static |
Helper method to install tracers on the selected simulation nodes.
nodes | Nodes on which to install tracer |
file | File to which traces will be written. If filename is -, then std::out is used |
averagingPeriod | How often data will be written into the trace file (default, every half second) |
Definition at line 84 of file ndn-l3-rate-tracer.cpp.
References ns3::ndn::g_tracers.
Referenced by Install(), and InstallAll().
|
static |
Helper method to install tracers on a specific simulation node.
nodes | Nodes on which to install tracer |
file | File to which traces will be written. If filename is -, then std::out is used |
averagingPeriod | How often data will be written into the trace file (default, every half second) |
Definition at line 122 of file ndn-l3-rate-tracer.cpp.
References ns3::ndn::g_tracers, and Install().
|
static |
Explicit request to remove all statically created tracers.
This method can be helpful if simulation scenario contains several independent run, or if it is desired to do a postprocessing of the resulting data
Definition at line 44 of file ndn-l3-rate-tracer.cpp.
References ns3::ndn::g_tracers.
|
static |
Helper method to install tracers on a specific simulation node.
nodes | Nodes on which to install tracer |
outputStream | Smart pointer to a stream |
averagingPeriod | How often data will be written into the trace file (default, every half second) |
Definition at line 158 of file ndn-l3-rate-tracer.cpp.
|
virtual |
Print head of the trace (e.g., for post-processing)
os | reference to output stream |
Implements ns3::ndn::L3Tracer.
Definition at line 206 of file ndn-l3-rate-tracer.cpp.
|
virtual |
Print current trace data.
os | reference to output stream |
Implements ns3::ndn::L3Tracer.
Definition at line 262 of file ndn-l3-rate-tracer.cpp.
References nfd::face::INVALID_FACEID, and PRINTER.
Referenced by ~L3RateTracer().
|
protectedvirtual |
Implements ns3::ndn::L3Tracer.
Definition at line 297 of file ndn-l3-rate-tracer.cpp.
|
protectedvirtual |
Implements ns3::ndn::L3Tracer.
Definition at line 308 of file ndn-l3-rate-tracer.cpp.
|
protectedvirtual |
Implements ns3::ndn::L3Tracer.
Definition at line 319 of file ndn-l3-rate-tracer.cpp.
|
protectedvirtual |
Implements ns3::ndn::L3Tracer.
Definition at line 330 of file ndn-l3-rate-tracer.cpp.
Implements ns3::ndn::L3Tracer.
Definition at line 341 of file ndn-l3-rate-tracer.cpp.
References ndn::lp::Nack::getInterest(), ndn::Interest::hasWire(), and ndn::Interest::wireEncode().
Implements ns3::ndn::L3Tracer.
Definition at line 352 of file ndn-l3-rate-tracer.cpp.
References ndn::lp::Nack::getInterest(), ndn::Interest::hasWire(), and ndn::Interest::wireEncode().
|
protectedvirtual |
Implements ns3::ndn::L3Tracer.
Definition at line 363 of file ndn-l3-rate-tracer.cpp.
References nfd::pit::Entry::getInRecords(), nfd::pit::Entry::getOutRecords(), and nfd::face::INVALID_FACEID.
|
protectedvirtual |
Implements ns3::ndn::L3Tracer.
Definition at line 380 of file ndn-l3-rate-tracer.cpp.
References Face, nfd::pit::Entry::getInRecords(), nfd::pit::Entry::getOutRecords(), and nfd::face::INVALID_FACEID.