Public Member Functions | List of all members
ndn::LpPacket Class Reference

An LpPacket represents an NDNLPv2 packet including header fields an an optional fragment. More...

#include <lp-packet.hpp>

Public Member Functions

const BlobgetFragmentWireEncoding () const
 Get the fragment wire encoding. More...
 
size_t countHeaderFields () const
 Get the number of header fields. More...
 
ptr_lib::shared_ptr< LpPacketHeaderField > & getHeaderField (int index)
 Get the header field at the given index. More...
 
void clear ()
 Remove all header fields and set the fragment to an isNull Blob.
 
void set (const LpPacketLite &lpPacketLite)
 Clear this LpPacket, and set the values by copying from lpPacketLite. More...
 

Detailed Description

An LpPacket represents an NDNLPv2 packet including header fields an an optional fragment.

This is an internal class which the application normally would not use. http://redmine.named-data.net/projects/nfd/wiki/NDNLPv2

Member Function Documentation

size_t ndn::LpPacket::countHeaderFields ( ) const
inline

Get the number of header fields.

This does not include the fragment.

Returns
The number of header fields.
const Blob& ndn::LpPacket::getFragmentWireEncoding ( ) const
inline

Get the fragment wire encoding.

Returns
The wire encoding, or an isNull Blob if not specified.
ptr_lib::shared_ptr<LpPacketHeaderField>& ndn::LpPacket::getHeaderField ( int  index)
inline

Get the header field at the given index.

Parameters
indexThe index, starting from 0. It is an error if index is greater to or equal to countHeaderFields().
Returns
The header field at the index.
void ndn::LpPacket::set ( const LpPacketLite lpPacketLite)

Clear this LpPacket, and set the values by copying from lpPacketLite.

Parameters
lpPacketLiteAn LpPacketLite object.

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