Syndicate::Data::Rnc Class Reference

#include <Syndicate/Data/Rnc.h>

List of all members.

Public Member Functions

uint8_t * unpack (uint8_t *input, unsigned &output_length) const
bool isRnc (uint8_t *input) const

Static Public Member Functions

static RncgetInstance (void)

Private Member Functions

 Rnc (void)
uint16_t crc (uint8_t const *data, unsigned len) const

Static Private Attributes

static uint16_t _crctab [256]
static const uint32_t _rnc_signature = 0x524E4301

Classes

struct  Header


Detailed Description

This class decompress RNC packed data. The format is deducted from the code source found at http://www.yoda.arachsys.com/dk/rnc.html The original tools to decompress RNC files is at


Constructor & Destructor Documentation

Syndicate::Data::Rnc::Rnc ( void   )  [private]


Member Function Documentation

static Rnc* Syndicate::Data::Rnc::getInstance ( void   )  [static]

Get an unique instance of the class.

uint8_t* Syndicate::Data::Rnc::unpack ( uint8_t *  input,
unsigned &  output_length 
) const

Unpack the given byte array.

Parameters:
[in] input is the compressed data array.
[out] output_length is the uncompressed length
Returns:
a pointer to the decompressed data or zero if it fails.
Warning:
The returned pointer must be freed by the user.

bool Syndicate::Data::Rnc::isRnc ( uint8_t *  input  )  const

Identify a data array as compressed or not.

Parameters:
[in] input is a buffer to test.
Returns:
true if the buffer is RNC compressed.

uint16_t Syndicate::Data::Rnc::crc ( uint8_t const *  data,
unsigned  len 
) const [private]

Compute the CRC of a buffer


Member Data Documentation

uint16_t Syndicate::Data::Rnc::_crctab[256] [static, private]

const uint32_t Syndicate::Data::Rnc::_rnc_signature = 0x524E4301 [static, private]


The documentation for this class was generated from the following file:
Generated on Sun Sep 30 13:08:36 2007 for libSyndicate by  doxygen 1.5.2