Data abstraction for Route. More...
#include <nfd-rib-entry.hpp>
Classes | |
class | Error |
Public Member Functions | |
Route () | |
Route (const Block &block) | |
uint64_t | getFaceId () const |
Route & | setFaceId (uint64_t faceId) |
uint64_t | getOrigin () const |
Route & | setOrigin (uint64_t origin) |
set Origin More... | |
uint64_t | getCost () const |
Route & | setCost (uint64_t cost) |
uint64_t | getFlags () const |
Route & | setFlags (uint64_t flags) |
set route inheritance flags More... | |
const time::milliseconds & | getExpirationPeriod () const |
Route & | setExpirationPeriod (const time::milliseconds &expirationPeriod) |
bool | hasInfiniteExpirationPeriod () const |
template<encoding::Tag TAG> | |
size_t | wireEncode (EncodingImpl< TAG > &block) const |
const Block & | wireEncode () const |
void | wireDecode (const Block &wire) |
Public Member Functions inherited from ndn::nfd::RibFlagsTraits< Route > | |
bool | isChildInherit () const |
bool | isRibCapture () const |
Static Public Attributes | |
static const time::milliseconds | INFINITE_EXPIRATION_PERIOD |
A route indicates the availability of content via a certain face and provides meta-information about the face.
Route := ROUTE-TYPE TLV-LENGTH FaceId Origin Cost Flags ExpirationPeriod?
Definition at line 51 of file nfd-rib-entry.hpp.
ndn::nfd::Route::Route | ( | ) |
Definition at line 44 of file nfd-rib-entry.cpp.
Referenced by ndn::nfd::Route::Error::Error(), and ndn::nfd::RibEntry::wireDecode().
|
explicit |
Definition at line 54 of file nfd-rib-entry.cpp.
References wireDecode().
|
inline |
Definition at line 69 of file nfd-rib-entry.hpp.
Referenced by ndn::nfd::operator<<().
|
inline |
Definition at line 75 of file nfd-rib-entry.hpp.
Referenced by nfd::rib::RibStatusPublisher::generate().
|
inline |
Definition at line 83 of file nfd-rib-entry.hpp.
Referenced by ndn::nfd::operator<<().
|
inline |
set Origin
origin | a code defined in ndn::nfd::RouteOrigin |
Definition at line 92 of file nfd-rib-entry.hpp.
Referenced by nfd::rib::RibStatusPublisher::generate().
|
inline |
Definition at line 100 of file nfd-rib-entry.hpp.
Referenced by ndn::nfd::operator<<().
|
inline |
Definition at line 106 of file nfd-rib-entry.hpp.
Referenced by nfd::rib::RibStatusPublisher::generate().
|
inline |
Definition at line 114 of file nfd-rib-entry.hpp.
Referenced by ndn::nfd::operator<<().
|
inline |
set route inheritance flags
flags | a bitwise OR'ed code from ndn::nfd::RouteFlags |
Definition at line 123 of file nfd-rib-entry.hpp.
Referenced by nfd::rib::RibStatusPublisher::generate().
|
inline |
Definition at line 133 of file nfd-rib-entry.hpp.
Referenced by ndn::nfd::operator<<().
|
inline |
Definition at line 139 of file nfd-rib-entry.hpp.
References INFINITE_EXPIRATION_PERIOD.
Referenced by nfd::rib::RibStatusPublisher::generate().
|
inline |
Definition at line 150 of file nfd-rib-entry.hpp.
References ndn::nfd::operator<<(), wireDecode(), and wireEncode().
Referenced by ndn::nfd::operator<<().
size_t ndn::nfd::Route::wireEncode | ( | EncodingImpl< TAG > & | block | ) | const |
Definition at line 61 of file nfd-rib-entry.cpp.
References ndn::tlv::nfd::Cost, ndn::tlv::nfd::ExpirationPeriod, ndn::tlv::nfd::FaceId, ndn::tlv::nfd::Flags, ndn::tlv::nfd::Origin, ndn::encoding::prependNonNegativeIntegerBlock(), and ndn::tlv::nfd::Route.
const Block & ndn::nfd::Route::wireEncode | ( | ) | const |
Definition at line 101 of file nfd-rib-entry.cpp.
References ndn::Block::hasWire().
Referenced by ndn::nfd::RibEntry::clearRoutes(), hasInfiniteExpirationPeriod(), and ndn::nfd::RibEntry::wireEncode().
void ndn::nfd::Route::wireDecode | ( | const Block & | wire | ) |
Definition at line 119 of file nfd-rib-entry.cpp.
References ndn::tlv::nfd::Cost, ndn::Block::elements_begin(), ndn::Block::elements_end(), ndn::tlv::nfd::ExpirationPeriod, ndn::tlv::nfd::FaceId, ndn::tlv::nfd::Flags, INFINITE_EXPIRATION_PERIOD, ndn::tlv::nfd::Origin, ndn::Block::parse(), ndn::encoding::readNonNegativeInteger(), ndn::tlv::nfd::Route, and ndn::Block::type().
Referenced by ndn::nfd::RibEntry::clearRoutes(), hasInfiniteExpirationPeriod(), ndn::nfd::RibEntry::RibEntry(), and Route().
|
static |
Definition at line 130 of file nfd-rib-entry.hpp.
Referenced by setExpirationPeriod(), and wireDecode().