<div dir="ltr"><div dir="ltr">Prajjwal, it depends on what you need to do.<br></div><div dir="ltr"><br></div><div dir="ltr">I think you should create a new ns-3/ndn application (e.g: ns3::ndn::CustomConsumerCbr). Since it is the application that will create the interest packets.<br></div><div dir="ltr"><br></div><div dir="ltr">It is common to use ndn::AppHelper to instantiate applications. If you need to pass any value to your new application, no problem, ndn::AppHelper supports this (SetAttribute).<br></div><div dir="ltr"><br></div>Regards,<br>Ygor Amaral<div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Apr 8, 2021 at 12:38 AM Prajjwal Singh <<a href="mailto:csb17053@tezu.ac.in" target="_blank">csb17053@tezu.ac.in</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>Thanks Ygor.</div><div>I have a scenario which uses consumerCbr for consumer nodes.</div><div>Will I have to write custom scenarios to specify the new interest fields?<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Apr 8, 2021 at 5:27 AM Ygor Amaral <<a href="mailto:ygor.amaral@gmail.com" target="_blank">ygor.amaral@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr">Hi Prajjwal,<div><br></div><div>I do not know if I fully understood your question.<br></div><div><br></div><div>ndnSIM has no helpers for creating new interest packet fields.<br></div><div><br></div><div>You need to change the Interest class (ndn-cxx library) to add new fields.<br></div><div><br></div><div>Path:</div><div>     - ndnSIM/ns-3/src/ndnSIM/ndn-cxx/ndn-cxx/interest.cpp<br></div><div>     - ndnSIM/ns-3/src/ndnSIM/ndn-cxx/ndn-cxx/interest.hpp<br></div><div><br></div><div>When creating a new interest packet, you will set the value of the new field, similar to how it is done with the other fields. For example:<br></div><div><br></div><div>...</div><div>shared_ptr<Interest> interest = make_shared<Interest>();<br></div><div>interest->setOldField(value1);<br></div><div>interest->setNewField(value2);<br></div><div>...</div><div>send(*interest);</div><div>...</div><div><br></div><div>Regards,<br>Ygor Amaral<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Apr 6, 2021 at 3:26 AM Prajjwal Singh <<a href="mailto:csb17053@tezu.ac.in" target="_blank">csb17053@tezu.ac.in</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>Hello all,</div><div>After adding a custom field, say Priority, to the interest packet, how can I make use of ndnSIM helpers to specify this Priority field in the interest packets, while installing and specifying prefix to consumer nodes in the simulating examples?</div><div><br></div><div>Thanks in advance,</div><div>Prajjwal Singh<br></div><div><br></div></div>
_______________________________________________<br>
ndnSIM mailing list<br>
<a href="mailto:ndnSIM@lists.cs.ucla.edu" target="_blank">ndnSIM@lists.cs.ucla.edu</a><br>
<a href="http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim" rel="noreferrer" target="_blank">http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim</a><br>
</blockquote></div>
</div>
</blockquote></div>
</blockquote></div></div></div>