NS-3 based Named Data Networking (NDN) simulator
ndnSIM: NDN, CCN, CCNx, content centric networks
API Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
ns3::ndn::cs::Probability::Random Class Reference

Content Store with freshness implementing Random cache replacement policy. More...

#include <introspected-doxygen.h>

Inheritance diagram for ns3::ndn::cs::Probability::Random:
Collaboration diagram for ns3::ndn::cs::Probability::Random:

Additional Inherited Members

- Public Types inherited from ns3::ndn::cs::ContentStoreWithProbability< random_policy_traits >
typedef ContentStoreImpl
< ndnSIM::multi_policy_traits
< boost::mpl::vector2
< ndnSIM::probability_policy_traits,
random_policy_traits > > > 
super
 
typedef
super::policy_container::template
index< 0 >::type 
probability_policy_container
 
- Public Types inherited from ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, random_policy_traits > > >
typedef
ndnSIM::trie_with_policy< Name,
ndnSIM::smart_pointer_payload_traits
< EntryImpl< ContentStoreImpl
< ndnSIM::multi_policy_traits
< boost::mpl::vector2
< ndnSIM::probability_policy_traits,
random_policy_traits >
> > >, Entry >
, ndnSIM::multi_policy_traits
< boost::mpl::vector2
< ndnSIM::probability_policy_traits,
random_policy_traits > > > 
super
 
typedef EntryImpl
< ContentStoreImpl
< ndnSIM::multi_policy_traits
< boost::mpl::vector2
< ndnSIM::probability_policy_traits,
random_policy_traits > > > > 
entry
 
- Public Member Functions inherited from ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, random_policy_traits > > >
virtual Ptr< DataLookup (Ptr< const Interest > interest)
 Find corresponding CS entry for the given interest. More...
 
virtual bool Add (Ptr< const Data > data)
 Add a new content to the content store. More...
 
virtual void Print (std::ostream &os) const
 Print out content store entries.
 
virtual uint32_t GetSize () const
 Get number of entries in content store.
 
virtual Ptr< EntryBegin ()
 Return first element of content store (no order guaranteed)
 
virtual Ptr< EntryEnd ()
 Return item next after last (no order guaranteed)
 
virtual Ptr< EntryNext (Ptr< Entry >)
 
const super::policy_container & GetPolicy () const
 
super::policy_container & GetPolicy ()
 
- Public Member Functions inherited from ns3::ndn::ContentStore
virtual ~ContentStore ()
 Virtual destructor.
 
virtual Ptr< cs::EntryNext (Ptr< cs::Entry >)=0
 Advance the iterator.
 
- Static Public Member Functions inherited from ns3::ndn::cs::ContentStoreWithProbability< random_policy_traits >
static TypeId GetTypeId ()
 
- Static Public Member Functions inherited from ns3::ndn::cs::ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, random_policy_traits > > >
static TypeId GetTypeId ()
 
- Static Public Member Functions inherited from ns3::ndn::ContentStore
static TypeId GetTypeId ()
 Interface ID. More...
 
static Ptr< ContentStoreGetContentStore (Ptr< Object > node)
 Static call to cheat python bindings.
 
- Protected Types inherited from ns3::ndn::ndnSIM::trie_with_policy< Name, ndnSIM::smart_pointer_payload_traits< EntryImpl< ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, random_policy_traits > > > >, Entry >, ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, random_policy_traits > > >
typedef trie< Name,
ndnSIM::smart_pointer_payload_traits
< EntryImpl< ContentStoreImpl
< ndnSIM::multi_policy_traits
< boost::mpl::vector2
< ndnSIM::probability_policy_traits,
random_policy_traits >
> > >, Entry >, typename
ndnSIM::multi_policy_traits
< boost::mpl::vector2
< ndnSIM::probability_policy_traits,
random_policy_traits >
>::policy_hook_type > 
parent_trie
 
typedef parent_trie::iterator iterator
 
typedef parent_trie::const_iterator const_iterator
 
typedef
ndnSIM::multi_policy_traits
< boost::mpl::vector2
< ndnSIM::probability_policy_traits,
random_policy_traits >
>::template policy
< trie_with_policy< Name,
ndnSIM::smart_pointer_payload_traits
< EntryImpl< ContentStoreImpl
< ndnSIM::multi_policy_traits
< boost::mpl::vector2
< ndnSIM::probability_policy_traits,
random_policy_traits >
> > >, Entry >
, ndnSIM::multi_policy_traits
< boost::mpl::vector2
< ndnSIM::probability_policy_traits,
random_policy_traits >
> >, parent_trie, typename
ndnSIM::multi_policy_traits
< boost::mpl::vector2
< ndnSIM::probability_policy_traits,
random_policy_traits >
>::template container_hook
< parent_trie >::type >::type 
policy_container
 
- Protected Member Functions inherited from ns3::ndn::ndnSIM::trie_with_policy< Name, ndnSIM::smart_pointer_payload_traits< EntryImpl< ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, random_policy_traits > > > >, Entry >, ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, random_policy_traits > > >
 trie_with_policy (size_t bucketSize=1, size_t bucketIncrement=1)
 
std::pair< iterator, bool > insert (const Name &key, typename ndnSIM::smart_pointer_payload_traits< EntryImpl< ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, random_policy_traits > > > >, Entry >::insert_type payload)
 
void erase (const Name &key)
 
void erase (iterator node)
 
void clear ()
 
bool modify (iterator position, Modifier mod)
 
iterator find_exact (const Name &key)
 Find a node that has the exact match with the key.
 
iterator longest_prefix_match (const Name &key)
 Find a node that has the longest common prefix with key (FIB/PIT lookup)
 
iterator longest_prefix_match_if (const Name &key, Predicate pred)
 Find a node that has the longest common prefix with key (FIB/PIT lookup)
 
iterator deepest_prefix_match (const Name &key)
 Const version of the longest common prefix match (semi-const, because there could be update of the policy anyways) More...
 
iterator deepest_prefix_match_if (const Name &key, Predicate pred)
 Find a node that has prefix at least as the key.
 
iterator deepest_prefix_match_if_next_level (const Name &key, Predicate pred)
 Find a node that has prefix at least as the key. More...
 
iterator end () const
 
const parent_triegetTrie () const
 
parent_triegetTrie ()
 
const policy_container & getPolicy () const
 
policy_container & getPolicy ()
 
- Static Protected Member Functions inherited from ns3::ndn::ndnSIM::trie_with_policy< Name, ndnSIM::smart_pointer_payload_traits< EntryImpl< ContentStoreImpl< ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, random_policy_traits > > > >, Entry >, ndnSIM::multi_policy_traits< boost::mpl::vector2< ndnSIM::probability_policy_traits, random_policy_traits > > >
static iterator s_iterator_to (typename parent_trie::iterator item)
 
- Protected Attributes inherited from ns3::ndn::ContentStore
TracedCallback< Ptr< const
Interest >, Ptr< const Data > > 
m_cacheHitsTrace
 trace of cache hits
 
TracedCallback< Ptr< const
Interest > > 
m_cacheMissesTrace
 trace of cache misses
 

Detailed Description

Content Store with freshness implementing Random cache replacement policy.

Doxygen introspection did not find any typical Config paths.

Attributes

  • CacheProbability: Set probability of caching in ContentStore. If 1, every content is cached. If 0, no content is cached.
    • Set with class: ns3::DoubleValue
    • Underlying type: double -1.79769e+308:1.79769e+308
    • Initial value: 1
    • Flags: construct write read

Attributes defined in parent class ns3::ndn::cs::ProbabilityImpl::Random

  • MaxSize: Set maximum number of entries in ContentStore. If 0, limit is not enforced
    • Set with class: ns3::UintegerValue
    • Underlying type: uint32_t 0:4294967295
    • Initial value: 100
    • Flags: construct write read

No TraceSources are defined for this type.

TraceSources defined in parent class ns3::ndn::cs::ProbabilityImpl::Random

  • DidAddEntry: Trace fired every time entry is successfully added to the cache

TraceSources defined in parent class ns3::ndn::ContentStore

  • CacheHits: Trace called every time there is a cache hit
  • CacheMisses: Trace called every time there is a cache miss

Definition at line 86 of file content-store-with-probability.cc.


The documentation for this class was generated from the following file: