Data abstraction for Adjacency.
More...
#include <adjacency.hpp>
Data abstraction for Adjacency.
Adjacency := ADJACENCY-TYPE TLV-LENGTH Name Uri Cost
- See also
- https://redmine.named-data.net/projects/nlsr/wiki/LSDB_DataSet
Definition at line 44 of file adjacency.hpp.
◆ Adjacency() [1/2]
| nlsr::tlv::Adjacency::Adjacency |
( |
| ) |
|
◆ Adjacency() [2/2]
| nlsr::tlv::Adjacency::Adjacency |
( |
const ndn::Block & |
block | ) |
|
|
explicit |
◆ getCost()
| uint64_t nlsr::tlv::Adjacency::getCost |
( |
| ) |
const |
|
inline |
◆ getName()
| const ndn::Name& nlsr::tlv::Adjacency::getName |
( |
| ) |
const |
|
inline |
◆ getUri()
| const std::string& nlsr::tlv::Adjacency::getUri |
( |
| ) |
const |
|
inline |
◆ setCost()
| Adjacency& nlsr::tlv::Adjacency::setCost |
( |
uint64_t |
cost | ) |
|
|
inline |
◆ setName()
| Adjacency& nlsr::tlv::Adjacency::setName |
( |
const ndn::Name & |
name | ) |
|
|
inline |
◆ setUri()
| Adjacency& nlsr::tlv::Adjacency::setUri |
( |
const std::string & |
uri | ) |
|
|
inline |
◆ wireDecode()
| void nlsr::tlv::Adjacency::wireDecode |
( |
const ndn::Block & |
wire | ) |
|
Populate this object by decoding the object contained in the given block.
Definition at line 86 of file adjacency.cpp.
◆ wireEncode() [1/2]
template<ndn::encoding::Tag TAG>
| size_t nlsr::tlv::Adjacency::wireEncode |
( |
ndn::EncodingImpl< TAG > & |
block | ) |
const |
TLV-encode this object using the implementation in from TAG.
This method TLV-encodes this Adjacency object using the implementation given by TAG. Usually two implementations are provided: a size estimator and a real encoder, which are used in sequence to allocate the necessary block size and then encode it.
- See also
- Adjacency::wireEncode()
Definition at line 48 of file adjacency.cpp.
◆ wireEncode() [2/2]
| const ndn::Block & nlsr::tlv::Adjacency::wireEncode |
( |
| ) |
const |
Create a TLV encoding of this object.
This function automates the process of guessing the necessary size of a block containing this object, and then creating a block and putting the TLV encoding into it.
- See also
- Adjacency::wireEncode(ndn::EncodingImpl<TAG>&)
Definition at line 68 of file adjacency.cpp.