NS-3 based Named Data Networking (NDN) simulator
ndnSIM 2.5: NDN, CCN, CCNx, content centric networks
API Documentation
ndn::lp::PrefixAnnouncementHeader Class Reference

represents a PrefixAnnouncement header field in NDNLP More...

#include <prefix-announcement-header.hpp>

Classes

class  Error
 

Public Member Functions

 PrefixAnnouncementHeader ()
 
 PrefixAnnouncementHeader (const Block &block)
 
 PrefixAnnouncementHeader (PrefixAnnouncement prefixAnn)
 constructs PrefixAnnouncementHeader using PrefixAnnouncement More...
 
template<encoding::Tag TAG>
size_t wireEncode (EncodingImpl< TAG > &encoder) const
 encodes the prefix announcement header to the wire format More...
 
void wireDecode (const Block &wire)
 
const optional< PrefixAnnouncement > & getPrefixAnn () const
 

Detailed Description

represents a PrefixAnnouncement header field in NDNLP

Definition at line 32 of file prefix-announcement-header.hpp.

Constructor & Destructor Documentation

◆ PrefixAnnouncementHeader() [1/3]

ndn::lp::PrefixAnnouncementHeader::PrefixAnnouncementHeader ( )
default

◆ PrefixAnnouncementHeader() [2/3]

ndn::lp::PrefixAnnouncementHeader::PrefixAnnouncementHeader ( const Block block)
explicit

Definition at line 30 of file prefix-announcement-header.cpp.

References wireDecode().

◆ PrefixAnnouncementHeader() [3/3]

ndn::lp::PrefixAnnouncementHeader::PrefixAnnouncementHeader ( PrefixAnnouncement  prefixAnn)
explicit

constructs PrefixAnnouncementHeader using PrefixAnnouncement

Exceptions
ErrorPrefixAnnouncement does not contain Data.

Definition at line 35 of file prefix-announcement-header.cpp.

References NDN_THROW, and nonstd::optional_lite::nullopt.

Member Function Documentation

◆ wireEncode()

template<encoding::Tag TAG>
size_t ndn::lp::PrefixAnnouncementHeader::wireEncode ( EncodingImpl< TAG > &  encoder) const

encodes the prefix announcement header to the wire format

Exceptions
Errorthis instance does not contain a PrefixAnnouncement.

Definition at line 45 of file prefix-announcement-header.cpp.

References ndn::lp::NDN_CXX_DEFINE_WIRE_ENCODE_INSTANTIATIONS(), NDN_THROW, nonstd::optional_lite::nullopt, and ndn::lp::tlv::PrefixAnnouncement.

◆ wireDecode()

void ndn::lp::PrefixAnnouncementHeader::wireDecode ( const Block wire)

◆ getPrefixAnn()

const optional<PrefixAnnouncement>& ndn::lp::PrefixAnnouncementHeader::getPrefixAnn ( ) const
inline

The documentation for this class was generated from the following files: