<html><head><meta http-equiv="Content-Type" content="text/html charset=windows-1252"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Apr 10, 2015, at 10:52 PM, Muhammad Hosain Abdollahi Sabet <<a href="mailto:M.AbdollahiSabet@mail.sbu.ac.ir" class="">M.AbdollahiSabet@mail.sbu.ac.ir</a>> wrote:</div><br class="Apple-interchange-newline"><div class="">


<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" class="">
<meta name="Generator" content="MS Exchange Server version 6.5.7652.24" class="">
<title class="">RE: [ndnSIM] How to install multiple prefixes in one producer</title>

<div class="">
<!-- Converted from text/plain format --><p class=""><font size="2" class="">Oops. Sorry.<br class="">
I meant like this:<br class="">
<br class="">
ndn::AppHelper producerHelper("ns3::ndn::Producer");<br class="">
producerHelper.SetPrefix("/prefix1");<br class="">
producerHelper.Install(nodes.Get(NODENUMBER));<br class="">
<br class="">
ndn::AppHelper producerHelper("ns3::ndn::Producer");<br class="">
producerHelper.SetPrefix("/prefix2");<br class="">
producerHelper.Install(nodes.Get(NODENUMBER));<br class="">
<br class="">
ndn::AppHelper producerHelper("ns3::ndn::Producer");<br class="">
producerHelper.SetPrefix("/prefix3");<br class="">
producerHelper.Install(nodes.Get(NODENUMBER));<br class=""></font></p></div></div></blockquote><div><br class=""></div><div>Yes. However, this can be simplified a bit (you don’t need to create multiple producerHelpers)</div><div><br class=""></div><div>ndn::AppHelper producerHelper("ns3::ndn::Producer");</div>producerHelper.SetPrefix("/prefix1");<br class="">producerHelper.Install(nodes.Get(NODENUMBER));<br class=""><br class="">producerHelper.SetPrefix("/prefix2");<br class="">producerHelper.Install(nodes.Get(NODENUMBER));<br class=""><br class="">producerHelper.SetPrefix("/prefix3");<br class="">producerHelper.Install(nodes.Get(NODENUMBER));<br class=""><br class="">* * *</div><div><br class=""></div><div>Another way to accomplish your goal is to create another Producer application, which would register and respond to multiple prefixes.</div><div><br class=""></div><div>—</div><div>Alex<br class=""><br class=""><blockquote type="cite" class=""><div class=""><div class=""><p class=""><font size="2" class="">
<br class="">
Right?<br class="">
<br class="">
Thanks,<br class="">
Sabet<br class="">
<br class="">
-----Original Message-----<br class="">
From: ndnSIM on behalf of Trade<br class="">
Sent: Sat 4/11/2015 2:54 AM<br class="">
To: Spyridon (Spyros) Mastorakis<br class="">
Cc: <a href="mailto:ndnsim@lists.cs.ucla.edu" class="">ndnsim@lists.cs.ucla.edu</a><br class="">
Subject: Re: [ndnSIM] How to install multiple prefixes in one producer<br class="">
<br class="">
Thanks.<br class="">
Do you mean that multiple producers can be installed at one node?<br class="">
<br class="">
On 4/10/15 9:29 AM, Spyridon (Spyros) Mastorakis wrote:<br class="">
> Hello,<br class="">
><br class="">
> you will need to install more than one producer applications on the node, because each producer application has been assumed to respond only to one prefix.<br class="">
><br class="">
> --<br class="">
> Spyridon (Spyros) Mastorakis<br class="">
> Personal Website: <a href="http://cs.ucla.edu/~mastorakis/" class="">http://cs.ucla.edu/~mastorakis/</a><br class="">
> Internet Research Laboratory<br class="">
> PhD Computer Science<br class="">
> UCLA<br class="">
><br class="">
><br class="">
><br class="">
><br class="">
>> On Apr 9, 2015, at 5:15 PM, Trade <<a href="mailto:trade20122012@gmail.com" class="">trade20122012@gmail.com</a>> wrote:<br class="">
>><br class="">
>> I want one producer can have multiple prefixes, but how to implement?<br class="">
>> Does this work?  or it only takes the last row ? Thanks<br class="">
>><br class="">
>>           ProducerHelper.SetPrefix (prefix1);<br class="">
>>           ProducerHelper.SetPrefix (prefix2);<br class="">
>>           ProducerHelper.SetPrefix (prefix3);<br class="">
>><br class="">
>> Trade<br class="">
>> _______________________________________________<br class="">
>> ndnSIM mailing list<br class="">
>> <a href="mailto:ndnSIM@lists.cs.ucla.edu" class="">ndnSIM@lists.cs.ucla.edu</a><br class="">
>> <a href="http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim" class="">http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim</a><br class="">
<br class="">
<br class="">
</font>
</p>

</div>
_______________________________________________<br class="">ndnSIM mailing list<br class=""><a href="mailto:ndnSIM@lists.cs.ucla.edu" class="">ndnSIM@lists.cs.ucla.edu</a><br class="">http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim<br class=""></div></blockquote></div><br class=""></body></html>