libhomegear-base  0.7
Base library for Homegear and Homegear family modules.
BaseLib::BinaryDecoder Class Reference

#include <BinaryDecoder.h>

Public Member Functions

 BinaryDecoder ()=default
 
 BinaryDecoder (bool ansi)
 
 BinaryDecoder (BaseLib::SharedObjects *baseLib)
 Dummy constructor for backwards compatability. More...
 
 BinaryDecoder (BaseLib::SharedObjects *baseLib, bool ansi)
 Dummy constructor for backwards compatability. More...
 
 ~BinaryDecoder ()=default
 
std::string decodeString (const std::vector< char > &encodedData, uint32_t &position)
 
std::string decodeString (const std::vector< uint8_t > &encodedData, uint32_t &position)
 

Static Public Member Functions

static int32_t decodeInteger (const std::vector< char > &encodedData, uint32_t &position)
 
static int32_t decodeInteger (const std::vector< uint8_t > &encodedData, uint32_t &position)
 
static int64_t decodeInteger64 (const std::vector< char > &encodedData, uint32_t &position)
 
static int64_t decodeInteger64 (const std::vector< uint8_t > &encodedData, uint32_t &position)
 
static uint8_t decodeByte (const std::vector< char > &encodedData, uint32_t &position)
 
static uint8_t decodeByte (const std::vector< uint8_t > &encodedData, uint32_t &position)
 
static std::vector< uint8_t > decodeBinary (const std::vector< char > &encodedData, uint32_t &position)
 
static std::vector< uint8_t > decodeBinary (const std::vector< uint8_t > &encodedData, uint32_t &position)
 
static bool decodeBoolean (const std::vector< char > &encodedData, uint32_t &position)
 
static bool decodeBoolean (const std::vector< uint8_t > &encodedData, uint32_t &position)
 
static double decodeFloat (const std::vector< char > &encodedData, uint32_t &position)
 
static double decodeFloat (const std::vector< uint8_t > &encodedData, uint32_t &position)
 

Protected Attributes

bool _ansi = false
 
std::shared_ptr< Ansi_ansiConverter
 

Constructor & Destructor Documentation

§ BinaryDecoder() [1/4]

BaseLib::BinaryDecoder::BinaryDecoder ( )
default

§ BinaryDecoder() [2/4]

BaseLib::BinaryDecoder::BinaryDecoder ( bool  ansi)
explicit

§ BinaryDecoder() [3/4]

BaseLib::BinaryDecoder::BinaryDecoder ( BaseLib::SharedObjects baseLib)
explicit

Dummy constructor for backwards compatability.

§ BinaryDecoder() [4/4]

BaseLib::BinaryDecoder::BinaryDecoder ( BaseLib::SharedObjects baseLib,
bool  ansi 
)

Dummy constructor for backwards compatability.

§ ~BinaryDecoder()

BaseLib::BinaryDecoder::~BinaryDecoder ( )
default

Member Function Documentation

§ decodeBinary() [1/2]

std::vector< uint8_t > BaseLib::BinaryDecoder::decodeBinary ( const std::vector< char > &  encodedData,
uint32_t &  position 
)
static

§ decodeBinary() [2/2]

std::vector< uint8_t > BaseLib::BinaryDecoder::decodeBinary ( const std::vector< uint8_t > &  encodedData,
uint32_t &  position 
)
static

§ decodeBoolean() [1/2]

bool BaseLib::BinaryDecoder::decodeBoolean ( const std::vector< char > &  encodedData,
uint32_t &  position 
)
static

§ decodeBoolean() [2/2]

bool BaseLib::BinaryDecoder::decodeBoolean ( const std::vector< uint8_t > &  encodedData,
uint32_t &  position 
)
static

§ decodeByte() [1/2]

uint8_t BaseLib::BinaryDecoder::decodeByte ( const std::vector< char > &  encodedData,
uint32_t &  position 
)
static

§ decodeByte() [2/2]

uint8_t BaseLib::BinaryDecoder::decodeByte ( const std::vector< uint8_t > &  encodedData,
uint32_t &  position 
)
static

§ decodeFloat() [1/2]

double BaseLib::BinaryDecoder::decodeFloat ( const std::vector< char > &  encodedData,
uint32_t &  position 
)
static

§ decodeFloat() [2/2]

double BaseLib::BinaryDecoder::decodeFloat ( const std::vector< uint8_t > &  encodedData,
uint32_t &  position 
)
static

§ decodeInteger() [1/2]

int32_t BaseLib::BinaryDecoder::decodeInteger ( const std::vector< char > &  encodedData,
uint32_t &  position 
)
static

§ decodeInteger() [2/2]

int32_t BaseLib::BinaryDecoder::decodeInteger ( const std::vector< uint8_t > &  encodedData,
uint32_t &  position 
)
static

§ decodeInteger64() [1/2]

int64_t BaseLib::BinaryDecoder::decodeInteger64 ( const std::vector< char > &  encodedData,
uint32_t &  position 
)
static

§ decodeInteger64() [2/2]

int64_t BaseLib::BinaryDecoder::decodeInteger64 ( const std::vector< uint8_t > &  encodedData,
uint32_t &  position 
)
static

§ decodeString() [1/2]

std::string BaseLib::BinaryDecoder::decodeString ( const std::vector< char > &  encodedData,
uint32_t &  position 
)

§ decodeString() [2/2]

std::string BaseLib::BinaryDecoder::decodeString ( const std::vector< uint8_t > &  encodedData,
uint32_t &  position 
)

Member Data Documentation

§ _ansi

bool BaseLib::BinaryDecoder::_ansi = false
protected

§ _ansiConverter

std::shared_ptr<Ansi> BaseLib::BinaryDecoder::_ansiConverter
protected

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