36 template<encoding::Tag TAG>
40 size_t totalLength = 0;
61 totalLength += encoder.prependVarNumber(totalLength);
80 m_wire = buffer.block();
228 m_nfdVersion = nfdVersion;
236 m_startTimestamp = startTimestamp;
244 m_currentTimestamp = currentTimestamp;
252 m_nNameTreeEntries = nNameTreeEntries;
260 m_nFibEntries = nFibEntries;
268 m_nPitEntries = nPitEntries;
276 m_nMeasurementsEntries = nMeasurementsEntries;
284 m_nCsEntries = nCsEntries;
292 m_nInInterests = nInInterests;
308 m_nInNacks = nInNacks;
316 m_nOutInterests = nOutInterests;
324 m_nOutData = nOutData;
332 m_nOutNacks = nOutNacks;
340 m_nSatisfiedInterests = nSatisfiedInterests;
348 m_nUnsatisfiedInterests = nUnsatisfiedInterests;
376 os <<
"GeneralStatus(NfdVersion: " << status.
getNfdVersion() <<
",\n"
386 <<
" Data: {in: " << status.
getNInData() <<
", "
Represents a TLV element of the NDN packet format.
element_const_iterator elements_begin() const noexcept
Equivalent to elements().begin().
element_const_iterator elements_end() const noexcept
Equivalent to elements().end().
bool hasWire() const noexcept
Check if the Block contains a fully encoded wire representation.
uint32_t type() const noexcept
Return the TLV-TYPE of the Block.
void reset() noexcept
Reset the Block to a default-constructed state.
void parse() const
Parse TLV-VALUE into sub-elements.
Represents NFD General Status dataset.
uint64_t getNPitEntries() const
ForwarderStatus & setNCsEntries(uint64_t nCsEntries)
ForwarderStatus & setStartTimestamp(const time::system_clock::time_point &startTimestamp)
ForwarderStatus & setNInData(uint64_t nInData)
const std::string & getNfdVersion() const
ForwarderStatus & setNMeasurementsEntries(uint64_t nMeasurementsEntries)
uint64_t getNInNacks() const
ForwarderStatus & setNSatisfiedInterests(uint64_t nSatisfiedInterests)
uint64_t getNOutNacks() const
ForwarderStatus & setNInNacks(uint64_t nInNacks)
uint64_t getNMeasurementsEntries() const
uint64_t getNFibEntries() const
uint64_t getNNameTreeEntries() const
ForwarderStatus & setNfdVersion(const std::string &nfdVersion)
uint64_t getNOutInterests() const
uint64_t getNOutData() const
ForwarderStatus & setNPitEntries(uint64_t nPitEntries)
uint64_t getNUnsatisfiedInterests() const
ForwarderStatus & setNOutInterests(uint64_t nOutInterests)
const Block & wireEncode() const
Encode ForwarderStatus as a Content block.
ForwarderStatus & setCurrentTimestamp(const time::system_clock::time_point ¤tTimestamp)
ForwarderStatus & setNInInterests(uint64_t nInInterests)
ForwarderStatus & setNFibEntries(uint64_t nFibEntries)
uint64_t getNCsEntries() const
uint64_t getNSatisfiedInterests() const
ForwarderStatus & setNUnsatisfiedInterests(uint64_t nUnsatisfiedInterests)
void wireDecode(const Block &wire)
Decode ForwarderStatus from a Content block.
const time::system_clock::time_point & getStartTimestamp() const
const time::system_clock::time_point & getCurrentTimestamp() const
ForwarderStatus & setNOutNacks(uint64_t nOutNacks)
uint64_t getNInInterests() const
uint64_t getNInData() const
ForwarderStatus & setNOutData(uint64_t nOutData)
ForwarderStatus & setNNameTreeEntries(uint64_t nNameTreeEntries)
::boost::chrono::time_point< system_clock > time_point
#define NDN_CXX_DEFINE_WIRE_ENCODE_INSTANTIATIONS(ClassName)
EncodingImpl< EstimatorTag > EncodingEstimator
uint64_t readNonNegativeInteger(const Block &block)
Read a non-negative integer from a TLV element.
size_t prependNonNegativeIntegerBlock(EncodingImpl< TAG > &encoder, uint32_t type, uint64_t value)
Prepend a TLV element containing a non-negative integer.
size_t prependStringBlock(EncodingImpl< TAG > &encoder, uint32_t type, std::string_view value)
Prepend a TLV element containing a string.
std::string readString(const Block &block)
Read the TLV-VALUE of a TLV element as a string.
EncodingImpl< EncoderTag > EncodingBuffer
Contains classes and functions related to the NFD Management protocol.
std::ostream & operator<<(std::ostream &os, FaceScope faceScope)
bool operator==(const ChannelStatus &a, const ChannelStatus &b)
constexpr system_clock::time_point fromUnixTimestamp(system_clock::duration d)
Convert UNIX timestamp to system_clock::time_point.
constexpr Duration toUnixTimestamp(const system_clock::time_point &tp)
Convert system_clock::time_point to UNIX timestamp.
::boost::chrono::milliseconds milliseconds