[ndnSIM] forwarding-strategy.cc
徐雅琨
11111015 at bjtu.edu.cn
Sun Mar 17 20:34:32 PDT 2013
Thanks very much, Alex.
newInterest->SetName (Create<Name> ("/some/new/name")) can work; (I missed Create<Name> () .)
I should read the source code carefully beforehand.
Yakun Xu
2013-03-18
徐雅琨
发件人: Alex Afanasyev
发送时间: 2013-03-18 09:37:36
收件人: "徐雅琨"
抄送: ndnsim
主题: Re: [ndnSIM] forwarding-strategy.cc
Hi Yakun,
If you want to create and send out a slightly modified Interest inside the forwarding strategy, you can do something similar to what is done in nacks.cc: you create a new Interest, based on the existing interest that you have and then "replace" necessary parts (name). For example,
...
Ptr<Interest> newInterest = Create<Interest> (*header);
newInterest->SetName (Create<Name> ("/some/new/name"));
Ptr<Packet> packet = Create<Packet> ();
nonNackInterest->AddHeader (*nonNackHeader);
...
---
Alex
On Mar 17, 2013, at 7:13 AM, "徐雅琨" <11111015 at bjtu.edu.cn> wrote:
Hi Alex,
I add few new bits in the name prefix as you suppose and these new bits in the prefix should not be handlled as the header name. So I wanna add a new header similiar to Ptr<const InterestHeader> header in forwarding-strategy.cc except for the name. In other words, I wanna reset the name in Ptr<const InterestHeader> header.
I guess the router can only read NDN package without any modification.
Confusing~~~~
祝您工作顺利,身体健康!
2013-03-17
徐雅琨
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.lists.cs.ucla.edu/pipermail/ndnsim/attachments/20130318/75ab0c01/attachment.html>
More information about the ndnSIM
mailing list