<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="">
<br class="">
<div>
<blockquote type="cite" class="">
<div class="">Begin forwarded message:</div>
<div class=""><br class="">
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;" class="">
<span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif; color:rgba(127, 127, 127, 1.0);" class=""><b class="">From:
</b></span><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif;" class="">Alex Afanasyev <<a href="mailto:aa@cs.fiu.edu" class="">aa@cs.fiu.edu</a>><br class="">
</span></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;" class="">
<span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif; color:rgba(127, 127, 127, 1.0);" class=""><b class="">Subject:
</b></span><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif;" class=""><b class="">Re: [Nfd-dev] General NFD status - reusing the functions to calculate CS PIT FIB entries</b><br class="">
</span></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;" class="">
<span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif; color:rgba(127, 127, 127, 1.0);" class=""><b class="">Date:
</b></span><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif;" class="">February 11, 2018 at 7:46:58 PM CST<br class="">
</span></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;" class="">
<span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif; color:rgba(127, 127, 127, 1.0);" class=""><b class="">To:
</b></span><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif;" class="">Aman Maldar <<a href="mailto:amanmaldar@gmail.com" class="">amanmaldar@gmail.com</a>><br class="">
</span></div>
<div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;" class="">
<span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif; color:rgba(127, 127, 127, 1.0);" class=""><b class="">Cc:
</b></span><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif;" class=""><a href="mailto:mini-ndn@lists.cs.ucla.edu" class="">mini-ndn@lists.cs.ucla.edu</a>, "<a href="mailto:nfd-dev@lists.cs.ucla.edu" class="">nfd-dev@lists.cs.ucla.edu</a>"
<<a href="mailto:nfd-dev@lists.cs.ucla.edu" class="">nfd-dev@lists.cs.ucla.edu</a>><br class="">
</span></div>
<br class="">
<br class="">
<div style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">
<br class="">
<div class=""><br class="">
<blockquote type="cite" class="">
<div class="">On Feb 11, 2018, at 8:04 PM, Aman Maldar <<a href="mailto:amanmaldar@gmail.com" class="">amanmaldar@gmail.com</a>> wrote:</div>
<br class="Apple-interchange-newline">
<div class="">
<div dir="ltr" class="">
<div class="">Hello,</div>
<div class=""><br class="">
</div>
<div class="">I want reuse some results of "a nfdc status show" command.</div>
<div class=""><br class="">
</div>
<div class="">I undestand, the above command executes the code to calculate number of entries in FIB, CS, PIT.</div>
</div>
</div>
</blockquote>
<div class=""><br class="">
</div>
<div class="">nfdc doesn't calculate anything, rather just requesting stats from NFD and then reporting it to you.</div>
<br class="">
<blockquote type="cite" class="">
<div class="">
<div dir="ltr" class="">
<div class=""><br class="">
</div>
<div class="">The file which call the command above is present in "/mini-ndn/NFD/nfdc/tools/main.cpp" (I hope this is correct, or guide me to correct one please)</div>
<div class=""><br class="">
</div>
<div class="">However, I am trying to dig deep into this to find out which is the
<b class="">single function</b> that I can reuse to calculate CS entries only or FIB entries only or PIT entries only.</div>
</div>
</div>
</blockquote>
<div class=""><br class="">
</div>
<div class="">Depending on how much time you want to spend on this, you could either use some unix pipe'ing to extract the line/number you need or write a tool that requests General Status Dataset from NFD (<a href="https://redmine.named-data.net/projects/nfd/wiki/ForwarderStatus" class="">https://redmine.named-data.net/projects/nfd/wiki/ForwarderStatus</a>) and
prints the number you are looking for.</div>
<div class=""><br class="">
</div>
<blockquote type="cite" class="">
<div class="">
<div dir="ltr" class="">
<div class=""><br class="">
</div>
<div class="">Can someone guide me on how to get the desired functions so that I can reuse it?</div>
</div>
</div>
</blockquote>
<div class=""><br class="">
</div>
<div class="">Things are made modular, so actual code is "a bit" burried. You can take a look here <a href="https://github.com/named-data/NFD/blob/master/tools/nfdc/forwarder-general-module.cpp" class="">https://github.com/named-data/NFD/blob/master/tools/nfdc/forwarder-general-module.cpp</a></div>
<div class=""><br class="">
</div>
<blockquote type="cite" class="">
<div class="">
<div dir="ltr" class="">
<div class=""><br class="">
</div>
<div class="">Thank you in advance.</div>
<div class=""><br class="">
</div>
-- <br class="">
<div class="gmail_signature">
<div dir="ltr" class="">
<div class="">
<div dir="ltr" class=""><b class=""><font size="2" class="">Regards,</font></b><font size="2" class=""><b class=""><i class=""><br class="">
</i><font size="4" class=""><span style="color:rgb(0,102,0)" class=""><span style="background-color:rgb(255,255,255)" class="">M<span class=""></span>r. Maldar Aman M.</span></span></font></b></font><font size="4" class=""><b class=""><span style="color:rgb(0,102,0)" class=""><span style="background-color:rgb(255,255,255)" class=""><span class=""></span><span class=""></span></span></span></b></font><br class="">
<b class="">University of Massachusetts, Lowell</b><br class="">
</div>
</div>
</div>
</div>
</div>
_______________________________________________<br class="">
Nfd-dev mailing list<br class="">
<a href="mailto:Nfd-dev@lists.cs.ucla.edu" class="">Nfd-dev@lists.cs.ucla.edu</a><br class="">
<a href="http://www.lists.cs.ucla.edu/mailman/listinfo/nfd-dev" class="">http://www.lists.cs.ucla.edu/mailman/listinfo/nfd-dev</a><br class="">
</div>
</blockquote>
</div>
<br class="">
<div class="">
<div dir="auto" style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space;" class="">
<div dir="auto" style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space;" class="">
<div dir="auto" style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space;" class="">
______________<br class="">
Alex Afanasyev<br class="">
Assistant Professor, SCIS, Florida International University<br class="">
11200 SW 8th Street, ECS Room 261B, Miami, FL 33199<br class="">
phone: +1.305.348.4960 (office); <a href="mailto:aa@cs.fiu.edu" class="">email: aa@cs.fiu.edu</a><br class="">
web: <a href="https://users.cs.fiu.edu/~afanasyev/" class="">https://users.cs.fiu.edu/~afanasyev/</a><br class="">
<br class="">
</div>
</div>
</div>
</div>
<br class="">
</div>
<br class="">
<br class="">
</div>
</blockquote>
</div>
<br class="">
</body>
</html>