[ndnSIM] calling dynamic variable from content-store-impl.hpp in another function

Zeinab Rezaiefar zeinab.rezaiefar at gmail.com
Thu Jul 7 06:26:48 PDT 2016


hello everyone,
I have defined public variable in class ContentStoreImpl (double
invalid_content)  in content-store-impl.hpp. furthermore I have change
these value in ContentStoreImpl<Policy>::Add (invalid_content++;) I want to
access this value through files in scratch folder .
therefore I include this path (#include
"ns3/ndnSIM/model/cs/content-store-impl.h").  I want to access it before
main function as below:

using namespace ns3;
void
CacheEntryRemoved(std::string context, Ptr<const ndn::cs::Entry> entry,
Time lifetime)
{

if (entry->GetData()->GetSignature()!=0){
//ContentStoreImpl a;
Ptr<ndn::cs::ContentStoreImpl> content;
content.invalid_content--;

}
}

however, I have received error  (mismatch at argument 1 in template
parameter list for ‘template<class T> class ns3::Ptr’)
is there anybody knows how I can access this value through this function.
I will become thankful, if I know your opinion
thanks in advance
best regards
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.lists.cs.ucla.edu/pipermail/ndnsim/attachments/20160707/ecc7b5d1/attachment.html>


More information about the ndnSIM mailing list