Container of PendingInterest, RegisteredPrefix, or InterestFilterRecord. More...
#include <record-container.hpp>
Public Types | |
using | Record = T |
using | Container = std::map< RecordId, Record > |
Public Member Functions | |
Record * | get (RecordId id) |
Retrieve record by ID. More... | |
template<typename ... TArgs> | |
Record & | put (RecordId id, TArgs &&... args) |
Insert a record with given ID. More... | |
RecordId | allocateId () |
template<typename ... TArgs> | |
Record & | insert (TArgs &&... args) |
Insert a record with newly assigned ID. More... | |
void | erase (RecordId id) |
void | clear () |
template<typename Visitor > | |
void | removeIf (const Visitor &f) |
Visit all records with the option to erase. More... | |
template<typename Visitor > | |
void | forEach (const Visitor &f) |
Visit all records. More... | |
NDN_CXX_NODISCARD bool | empty () const noexcept |
size_t | size () const noexcept |
Public Attributes | |
util::Signal< RecordContainer< T > > | onEmpty |
Signals when container becomes empty. More... | |
Container of PendingInterest, RegisteredPrefix, or InterestFilterRecord.
T | record type |
Definition at line 36 of file record-container.hpp.
using ndn::detail::RecordContainer< T >::Record = T |
Definition at line 77 of file record-container.hpp.
using ndn::detail::RecordContainer< T >::Container = std::map<RecordId, Record> |
Definition at line 78 of file record-container.hpp.
|
inline |
Retrieve record by ID.
Definition at line 83 of file record-container.hpp.
Referenced by ndn::Face::Impl::shutdown().
|
inline |
Insert a record with given ID.
Definition at line 96 of file record-container.hpp.
Referenced by ndn::Face::Impl::expressInterest(), ndn::Face::Impl::registerPrefix(), and ndn::Face::Impl::setInterestFilter().
|
inline |
Definition at line 110 of file record-container.hpp.
Referenced by ndn::Face::Impl::registerPrefix().
|
inline |
Insert a record with newly assigned ID.
Definition at line 119 of file record-container.hpp.
Referenced by ndn::Face::Impl::processIncomingInterest(), and ndn::Face::Impl::registerPrefix().
|
inline |
Definition at line 125 of file record-container.hpp.
Referenced by ndn::Face::Impl::shutdown().
|
inline |
Definition at line 134 of file record-container.hpp.
Referenced by ndn::Face::Impl::removeAllPendingInterests(), and ndn::Face::Impl::shutdown().
|
inline |
Visit all records with the option to erase.
Visitor | function of type 'bool f(Record& record)' |
f | visitor function, return true to erase record |
Definition at line 146 of file record-container.hpp.
Referenced by ndn::Face::Impl::nackPendingInterests(), and ndn::Face::Impl::satisfyPendingInterests().
|
inline |
Visit all records.
Visitor | function of type 'void f(Record& record)' |
f | visitor function |
Definition at line 168 of file record-container.hpp.
Referenced by ndn::Face::Impl::shutdown().
|
inlinenoexcept |
Definition at line 177 of file record-container.hpp.
Referenced by ndn::Face::Impl::Impl().
|
inlinenoexcept |
Definition at line 183 of file record-container.hpp.
util::Signal<RecordContainer<T> > ndn::detail::RecordContainer< T >::onEmpty |
Signals when container becomes empty.
Definition at line 191 of file record-container.hpp.
Referenced by ndn::Face::Impl::Impl().