[ndnSIM] Inducing waiting delay in nodes, Simulator::Schedule problem
Rajvardhan Deshmukh
rdeshmukh at umass.edu
Sun Mar 19 14:17:43 PDT 2017
Hi,
Thank you for helping with the mobility GetObject.I want to further
induce delay in the interset forwarding by the nodes
I tried the following:
void WaitStrategy::afterReceiveInterest(const Face& inFace, const
Interest& interest, const shared_ptr<pit::Entry>& pitEntry)
{
const fib::Entry& fibEntry = this->lookupFib(*pitEntry);
const fib::NextHopList& nexthops = fibEntry.getNextHops();
float tGap= 0.00006;
fib::NextHopList::const_iterator it = nexthops.begin();
while(it!=nexthops.end())
{
if (!wouldViolateScope(inFace, interest, it->getFace()) &&
canForwardToLegacy(*pitEntry, it->getFace()))
{
this->sendInterest(pitEntry, it->getFace(), interest);
ns3::Simulator::Schedule(ns3::Seconds(tGap),
&WaitStrategy::SendAfterDelay,it);
}
else{++it;}
}
if (!hasPendingOutRecords(*pitEntry)) {
this->rejectPendingInterest(pitEntry);
}
}
void WaitStrategy::SendAfterDelay(fib::NextHopList::const_iterator& it)
{
++it;
}
I tried this and it give following error:(there is some problem with
scheduling the function after a certain delay)
/src/ndnSIM/NFD/daemon/fw/Wait-strategy.cpp:177:104: required from
here
./ns3/make-event.h:384:52: error: incomplete type
‘ns3::EventMemberImplObjTraits<std::shared_ptr<nfd::pit::Entry> >’ used
in nested name specifier
(EventMemberImplObjTraits<OBJ>::GetReference
(m_obj).*m_function)(m_a1, m_a2);
Thank you,
Raj
More information about the ndnSIM
mailing list