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

A BinaryXmlEncoder extends a C ndn_BinaryXmlEncoder struct and wraps related functions. More...

#include <binary-xml-encoder.hpp>

Inheritance diagram for ndn::BinaryXmlEncoder:
ndn_BinaryXmlEncoder

Public Member Functions

 BinaryXmlEncoder (size_t initialLength=16)
 Initialize the base ndn_BinaryXmlEncoder struct with the initialLength. More...
 
const ptr_lib::shared_ptr< std::vector< uint8_t > > & getOutput ()
 Resize the output vector to the correct encoding length and return. More...
 

Public Attributes

DynamicUInt8Vector output_
 
- Public Attributes inherited from ndn_BinaryXmlEncoder
struct ndn_DynamicUInt8Arrayoutput
 A pointer to a ndn_DynamicUInt8Array which receives the encoded output.
 
size_t offset
 the offset into output.array for the next encoding
 

Detailed Description

A BinaryXmlEncoder extends a C ndn_BinaryXmlEncoder struct and wraps related functions.

Constructor & Destructor Documentation

ndn::BinaryXmlEncoder::BinaryXmlEncoder ( size_t  initialLength = 16)
inline

Initialize the base ndn_BinaryXmlEncoder struct with the initialLength.

Use simpleRealloc.

Parameters
initialLengthThe initial size of the output. If omitted, use 16.

Member Function Documentation

const ptr_lib::shared_ptr<std::vector<uint8_t> >& ndn::BinaryXmlEncoder::getOutput ( )
inline

Resize the output vector to the correct encoding length and return.

Returns
The encoding as a shared_ptr. Assume that the caller now owns the vector.

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