A simple Interest-sink applia simple Interest-sink application. More...
#include <ndn-producer.h>
Public Member Functions | |
void | OnInterest (Ptr< const Interest > interest) |
Method that will be called every time new Interest arrives. More... | |
Public Member Functions inherited from ns3::ndn::App | |
App () | |
Default constructor. | |
uint32_t | GetId () const |
Get application ID (ID of applications face) | |
virtual void | OnNack (Ptr< const Interest > interest) |
Method that will be called every time new NACK arrives. More... | |
virtual void | OnData (Ptr< const Data > contentObject) |
Method that will be called every time new Data arrives. More... | |
Static Public Member Functions | |
static TypeId | GetTypeId (void) |
Static Public Member Functions inherited from ns3::ndn::App | |
static TypeId | GetTypeId () |
Protected Member Functions | |
virtual void | StartApplication () |
Called at time specified by Start. | |
virtual void | StopApplication () |
Called at time specified by Stop. | |
Protected Member Functions inherited from ns3::ndn::App | |
virtual void | DoDispose () |
Do cleanup when application is destroyed. | |
Additional Inherited Members | |
Protected Attributes inherited from ns3::ndn::App | |
bool | m_active |
Flag to indicate that application is active (set by StartApplication and StopApplication) | |
Ptr< Face > | m_face |
automatically created application face through which application communicates | |
TracedCallback< Ptr< const Interest >, Ptr< App >, Ptr < Face > > | m_receivedInterests |
App-level trace of received Interests. | |
TracedCallback< Ptr< const Interest >, Ptr< App >, Ptr < Face > > | m_receivedNacks |
App-level trace of received NACKs. | |
TracedCallback< Ptr< const Data >, Ptr< App >, Ptr< Face > > | m_receivedDatas |
App-level trace of received Data. | |
TracedCallback< Ptr< const Interest >, Ptr< App >, Ptr < Face > > | m_transmittedInterests |
App-level trace of transmitted Interests. | |
TracedCallback< Ptr< const Data >, Ptr< App >, Ptr< Face > > | m_transmittedDatas |
App-level trace of transmitted Data. | |
A simple Interest-sink applia simple Interest-sink application.
A simple Interest-sink applia simple Interest-sink application, which replying every incoming Interest with Data packet with a specified size and name same as in Interest.cation, which replying every incoming Interest with Data packet with a specified size and name same as in Interest.
ns3::ndn::Producer is accessible through the following paths with Config::Set and Config::Connect:
No TraceSources are defined for this type.
Definition at line 43 of file ndn-producer.h.
|
virtual |
Method that will be called every time new Interest arrives.
interest | Interest header |
packet | "Payload" of the interests packet. The actual payload should be zero, but packet itself may be useful to get packet tags |
Reimplemented from ns3::ndn::App.
Definition at line 122 of file ndn-producer.cc.
References ns3::ndn::App::GetId(), ns3::ndn::App::m_active, ns3::ndn::App::m_face, ns3::ndn::App::m_transmittedDatas, ns3::ndn::App::OnInterest(), and ns3::ndn::Name::size().