Base class for NDN content store. More...
#include <ndn-content-store.h>
Public Member Functions | |
virtual | ~ContentStore () |
Virtual destructor. | |
virtual Ptr< Data > | Lookup (Ptr< const Interest > interest)=0 |
Find corresponding CS entry for the given interest. More... | |
virtual bool | Add (Ptr< const Data > data)=0 |
Add a new content to the content store. More... | |
virtual void | Print (std::ostream &os) const =0 |
Print out content store entries. | |
virtual uint32_t | GetSize () const =0 |
Get number of entries in content store. | |
virtual Ptr< cs::Entry > | Begin ()=0 |
Return first element of content store (no order guaranteed) | |
virtual Ptr< cs::Entry > | End ()=0 |
Return item next after last (no order guaranteed) | |
virtual Ptr< cs::Entry > | Next (Ptr< cs::Entry >)=0 |
Advance the iterator. | |
Static Public Member Functions | |
static TypeId | GetTypeId () |
Interface ID. More... | |
static Ptr< ContentStore > | GetContentStore (Ptr< Object > node) |
Static call to cheat python bindings. | |
Protected Attributes | |
TracedCallback< Ptr< const Interest >, Ptr< const Data > > | m_cacheHitsTrace |
trace of cache hits | |
TracedCallback< Ptr< const Interest > > | m_cacheMissesTrace |
trace of cache misses | |
Base class for NDN content store.
Particular implementations should implement Lookup, Add, and Print methods
Doxygen introspection did not find any typical Config paths.
No Attributes are defined for this type.
Definition at line 105 of file ndn-content-store.h.
|
pure virtual |
Add a new content to the content store.
header | Fully parsed Data |
packet | Fully formed Ndn packet to add to content store (will be copied and stripped down of headers) |
Implemented in ns3::ndn::cs::ContentStoreImpl< Policy >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< lru_policy_traits, ndnSIM::freshness_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< Policy, ndnSIM::lifetime_stats_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< fifo_policy_traits >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, fifo_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< lru_policy_traits, ndnSIM::lifetime_stats_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< Policy, ndnSIM::freshness_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< lfu_policy_traits, ndnSIM::lifetime_stats_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< fifo_policy_traits, ndnSIM::freshness_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< fifo_policy_traits, ndnSIM::lifetime_stats_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< lfu_policy_traits >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< random_policy_traits, ndnSIM::freshness_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< random_policy_traits, ndnSIM::lifetime_stats_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, random_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, lfu_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< random_policy_traits >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< lfu_policy_traits, ndnSIM::freshness_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< lru_policy_traits >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, Policy > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, lru_policy_traits > > >, ns3::ndn::cs::Nocache, ns3::ndn::cs::ContentStoreWithFreshness< Policy >, ns3::ndn::cs::ContentStoreWithFreshness< fifo_policy_traits >, ns3::ndn::cs::ContentStoreWithFreshness< lfu_policy_traits >, ns3::ndn::cs::ContentStoreWithFreshness< random_policy_traits >, and ns3::ndn::cs::ContentStoreWithFreshness< lru_policy_traits >.
|
static |
Interface ID.
Definition at line 38 of file ndn-content-store.cc.
References m_cacheHitsTrace, and m_cacheMissesTrace.
Find corresponding CS entry for the given interest.
interest | Interest for which matching content store entry will be searched |
If an entry is found, it is promoted to the top of most recent used entries index,
Implemented in ns3::ndn::cs::ContentStoreImpl< Policy >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< lru_policy_traits, ndnSIM::freshness_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< Policy, ndnSIM::lifetime_stats_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< fifo_policy_traits >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, fifo_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< lru_policy_traits, ndnSIM::lifetime_stats_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< Policy, ndnSIM::freshness_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< lfu_policy_traits, ndnSIM::lifetime_stats_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< fifo_policy_traits, ndnSIM::freshness_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< fifo_policy_traits, ndnSIM::lifetime_stats_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< lfu_policy_traits >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< random_policy_traits, ndnSIM::freshness_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< random_policy_traits, ndnSIM::lifetime_stats_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, random_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, lfu_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< random_policy_traits >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< lfu_policy_traits, ndnSIM::freshness_policy_traits > > >, ns3::ndn::cs::ContentStoreImpl< lru_policy_traits >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, Policy > > >, ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, lru_policy_traits > > >, and ns3::ndn::cs::Nocache.