<div dir="auto">Thank you so much for your effort. I'm surly looking into it. :) </div><br><div class="gmail_quote"><div dir="ltr">On Sun, May 27, 2018, 12:23 AM Spyridon (Spyros) Mastorakis <<a href="mailto:mastorakis@cs.ucla.edu">mastorakis@cs.ucla.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Junxiao,<br>
<br>
there are 2 different things: design and simulation code.<br>
<br>
We have built the simulator as a tool for the community to experiment with NDN, and we should make their life easier instead of more complicated. Therefore, in my humble opinion, it is fine if someone wants to reduce the coding complexity (not all the users are equally comfortable with software development), and create a more “hacky” implementation to make things work and do some preliminary evaluation. ndnSIM is a research tool, and serves the purpose of enabling people to experiment fast with different design alternatives.<br>
<br>
@Mudasir, I have implemented some wire encoding/decoding for a more complex data structure than the vector of names that you need. Please take a look here:<br>
<br>
<a href="https://github.com/kchou1/scenario-ntorrent/commit/750e92e9813c4022b95ba19995a4d517c9ec381c" rel="noreferrer noreferrer" target="_blank">https://github.com/kchou1/scenario-ntorrent/commit/750e92e9813c4022b95ba19995a4d517c9ec381c</a><br>
<br>
Look for the EncodeContent and DecodeIBFAndComputeRearestPiece methods.<br>
<br>
Thanks,<br>
<br>
Spyridon (Spyros) Mastorakis<br>
Personal Website: <a href="http://cs.ucla.edu/~mastorakis/" rel="noreferrer noreferrer" target="_blank">http://cs.ucla.edu/~mastorakis/</a><br>
Internet Research Laboratory<br>
Computer Science Department<br>
UCLA<br>
<br>
> On May 26, 2018, at 11:56 AM, Junxiao Shi <<a href="mailto:shijunxiao@email.arizona.edu" target="_blank" rel="noreferrer">shijunxiao@email.arizona.edu</a>> wrote:<br>
> <br>
> Hi Mudasir<br>
> <br>
> I have tried adding another "Name" type of field in Interest packet.<br>
> What's the semantics of this new field?<br>
> It's usually a wrong design if you need a secondary name.<br>
> <br>
> * To guide forwarding: use ForwardingHint field.<br>
> * To give additional parameters to the producer: append those parameters to the name. In case producer must return a Data generated by some other node, encapsulate that Data into a new Data that matches the Interest.<br>
> * To indicate who expressed the Interest: you shouldn't indicate who expressed the Interest, unless it changes the Data. In that case, see the second point.<br>
> <br>
> <br>
> in wireDecode method:<br>
> m_Name2.wireDecode(m_wire.get(tlv::Name2));<br>
> <br>
> Error:<br>
> When I'm running scenario, its builds successfully. But after linking files and before launching the simulator it gives following error:<br>
> <br>
> terminate called after throwing an instance of 'boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<ndn::Block::Error> >'<br>
>   what():  (Block::get) Requested a non-existed type [10] from Block<br>
> <br>
> This error message indicates Nonce element (TLV-TYPE 0x0A ie decimal 10) is missing.<br>
> <br>
> Yours, Junxiao<br>
<br>
</blockquote></div>