represents a base class for CS entry More...
#include <cs-entry.hpp>
Public Member Functions | |
const Data & | getData () const |
const Name & | getName () const |
const Name & | getFullName () const |
bool | isUnsolicited () const |
const time::steady_clock::TimePoint & | getStaleTime () const |
bool | isStale () const |
checks if the stored Data is stale now More... | |
bool | canSatisfy (const Interest &interest) const |
determines whether Interest can be satisified by the stored Data More... | |
bool | hasData () const |
void | setData (shared_ptr< const Data > data, bool isUnsolicited) |
replaces the stored Data More... | |
void | setData (const Data &data, bool isUnsolicited) |
replaces the stored Data More... | |
void | updateStaleTime () |
refreshes stale time relative to current time More... | |
void | reset () |
clears the entry More... | |
represents a base class for CS entry
Definition at line 36 of file cs-entry.hpp.
|
inline |
Definition at line 43 of file cs-entry.hpp.
References hasData().
Referenced by nfd::cs::EntryImpl::operator<(), and nfd::cs::EntryImpl::unsetUnsolicited().
|
inline |
Definition at line 53 of file cs-entry.hpp.
References hasData().
|
inline |
Definition at line 63 of file cs-entry.hpp.
References hasData().
|
inline |
Definition at line 73 of file cs-entry.hpp.
References hasData().
Referenced by hasData(), nfd::cs::Cs::insert(), and setData().
|
inline |
time::steady_clock::TimePoint::max() | if the stored Data never expires |
Definition at line 84 of file cs-entry.hpp.
References canSatisfy(), hasData(), and isStale().
Referenced by nfd::cs::EntryImpl::canStale().
bool nfd::cs::Entry::isStale | ( | ) | const |
checks if the stored Data is stale now
Definition at line 41 of file cs-entry.cpp.
References hasData(), and ndn::time::steady_clock::now().
Referenced by canSatisfy(), and getStaleTime().
bool nfd::cs::Entry::canSatisfy | ( | const Interest & | interest | ) | const |
determines whether Interest can be satisified by the stored Data
Definition at line 60 of file cs-entry.cpp.
References ndn::Interest::getMustBeFresh(), hasData(), isStale(), and ndn::Interest::matchesData().
Referenced by nfd::cs::Cs::find(), and getStaleTime().
|
inline |
Definition at line 107 of file cs-entry.hpp.
References isUnsolicited(), and setData().
Referenced by canSatisfy(), nfd::cs::EntryImpl::EntryImpl(), getData(), getFullName(), getName(), getStaleTime(), isStale(), isUnsolicited(), and updateStaleTime().
void nfd::cs::Entry::setData | ( | shared_ptr< const Data > | data, |
bool | isUnsolicited | ||
) |
replaces the stored Data
Definition at line 32 of file cs-entry.cpp.
References isUnsolicited(), and updateStaleTime().
Referenced by nfd::cs::EntryImpl::EntryImpl(), hasData(), setData(), and nfd::cs::EntryImpl::unsetUnsolicited().
|
inline |
replaces the stored Data
Definition at line 120 of file cs-entry.hpp.
References isUnsolicited(), reset(), setData(), and updateStaleTime().
void nfd::cs::Entry::updateStaleTime | ( | ) |
refreshes stale time relative to current time
Definition at line 48 of file cs-entry.cpp.
References hasData(), and ndn::time::steady_clock::now().
Referenced by nfd::cs::Cs::insert(), and setData().
void nfd::cs::Entry::reset | ( | ) |
clears the entry
Definition at line 75 of file cs-entry.cpp.
Referenced by setData().