Bugzilla – Bug 225
NodeList Total Count
Last modified: 2008-07-01 13:32:39 UTC
Currently NodeList does not have a method to fetch the total number of nodes, though it does present a GetNode(uint32_t n) method. Note that NodeListPriv has this function, but it is not exposed in NodeList. It seems natural to include the GetNNodes() function if a GetNode(n) function is presented. This would be useful in cases where some generic code is interacting with the NodeList, i.e. to pick a random node, but doesn't necessarily know how many nodes the simulation script created.
sounds good.
Created attachment 171 [details] Add NodeList::GetNNodes() method. Attaching a patch in hopes of getting this minor fix included in RC1.
Upping priority, CC'ing Craig explicitly to get this noticed for RC1.