<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class="">Hi Saran,</div><div class=""><br class=""></div><div class="">The solution you found is getting access to nodeId from the ndnSIM 1.0 strategy.  For the caching policy, you can do the following:</div><div class=""><br class=""></div><div class="">   item->payload()->GetContentStore()->GetObject<Node>()->GetId()</div><div class=""><br class=""></div><div class="">You can also use the following (cheaty) solution that can work in most of the places:</div><div class=""><br class=""></div><div class="">   Simulator::GetContext();  // context ID == nodeId</div><div class=""><br class=""></div><div class="">--</div><div class="">Alex</div><br class=""><div><blockquote type="cite" class=""><div class="">On Dec 28, 2015, at 1:05 AM, Saran Tarnoi <<a href="mailto:sarantarnoi@gmail.com" class="">sarantarnoi@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">Dear All,<div class=""><br class=""></div><div class="">I would like to get node id (or the node name) while being in lru-policy.hpp for logging purpose.</div><div class="">I am using ndnSIM-2.0. A solution found at <a href="http://www.lists.cs.ucla.edu/pipermail/ndnsim/2014-May/001307.html" class="">http://www.lists.cs.ucla.edu/pipermail/ndnsim/2014-May/001307.html</a> did not work. I have no idea how I can get a pointer to Node from here.</div><div class=""><br class=""></div><div class="">Could you give me some pieces of advice?<br class=""></div><div class=""><br class=""></div><div class="">Thanks a lot in advance for your help.<br clear="all" class=""><div class=""><br class=""></div>-- <br class=""><div class=""><div dir="ltr" class="">Best regards,<div class="">Saran Tarnoi</div></div></div></div></div></div></blockquote></div></body></html>