$search

castor::encoding::CNER Class Reference

#include <CNER.h>

Inheritance diagram for castor::encoding::CNER:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 CNER (const char *x, size_t offset, size_t length)
 CNER (const char *x, size_t length)
 CNER (const BytesPtr x, size_t offset)
 CNER ()
void commit ()
DecoderPtr createDecoder (const char *x, size_t offset, size_t length)
DecoderPtr createDecoder (const char *x, size_t length)
DecoderPtr createDecoder (const BytesPtr x, size_t offset=0)
EncoderPtr createEncoder ()
castor::net::NetAddress decAddress ()
bool decBool ()
BytesPtr decBytes (size_t length)
double decDouble ()
float decFloat ()
short decInt16 ()
long decInt32 ()
long long decInt64 ()
char decInt8 ()
size_t decLength ()
std::string decString ()
unsigned short decUInt16 ()
unsigned long decUInt32 ()
unsigned long long decUInt64 ()
unsigned char decUInt8 ()
void encAddress (const castor::net::NetAddress &x)
void encBool (bool x)
void encBytes (const char *x, size_t offset, size_t length)
void encBytes (const char *x, size_t length)
void encBytes (const Bytes &x, size_t offset, size_t length)
void encBytes (const Bytes &x)
void encDouble (double x)
void encFloat (float x)
void encInt16 (short x)
void encInt32 (long x)
void encInt64 (long long x)
void encInt8 (char x)
void encLength (size_t x)
void encString (const std::string x)
void encUInt16 (unsigned short x)
void encUInt32 (unsigned long x)
void encUInt64 (unsigned long long x)
void encUInt8 (unsigned char x)
const char * getBuffer ()
BytesPtr getBytes ()
size_t getLength ()
size_t getPosition ()
void mark ()
void reset ()
void rollback ()
void seek (long offset)
void switchEndianness (bool yes)
 ~CNER ()

Private Types

enum  { encode, decode }

Private Member Functions

void readInternal (char *data, size_t length, bool ignoreEndian=false)
void writeInternal (const char *data, size_t length, bool ignoreEndian=false)

Private Attributes

std::stringstream buffer
bool doSwitchEndian
size_t length
bool marked
size_t marker
enum castor::encoding::CNER:: { ... }  mode

Detailed Description

Definition at line 11 of file CNER.h.


Member Enumeration Documentation

anonymous enum [private]
Enumerator:
encode 
decode 

Definition at line 72 of file CNER.h.


Constructor & Destructor Documentation

castor::encoding::CNER::CNER (  )  [inline]

Definition at line 76 of file CNER.h.

castor::encoding::CNER::CNER ( const BytesPtr  x,
size_t  offset 
) [inline]

Definition at line 82 of file CNER.h.

castor::encoding::CNER::CNER ( const char *  x,
size_t  length 
) [inline]

Definition at line 88 of file CNER.h.

castor::encoding::CNER::CNER ( const char *  x,
size_t  offset,
size_t  length 
) [inline]

Definition at line 94 of file CNER.h.

castor::encoding::CNER::~CNER (  )  [inline]

Definition at line 101 of file CNER.h.


Member Function Documentation

void castor::encoding::CNER::commit (  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 167 of file CNER.h.

DecoderPtr castor::encoding::CNER::createDecoder ( const char *  x,
size_t  offset,
size_t  length 
) [inline, virtual]

Implements castor::Encoder.

Definition at line 115 of file CNER.h.

DecoderPtr castor::encoding::CNER::createDecoder ( const char *  x,
size_t  length 
) [inline, virtual]

Implements castor::Encoder.

Definition at line 111 of file CNER.h.

DecoderPtr castor::encoding::CNER::createDecoder ( const BytesPtr  x,
size_t  offset = 0 
) [inline, virtual]

Implements castor::Encoder.

Definition at line 107 of file CNER.h.

EncoderPtr castor::encoding::CNER::createEncoder (  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 103 of file CNER.h.

castor::net::NetAddress castor::encoding::CNER::decAddress (  )  [inline, virtual]

Implements castor::Decoder.

Definition at line 415 of file CNER.h.

bool castor::encoding::CNER::decBool (  )  [inline, virtual]

Implements castor::Decoder.

Definition at line 340 of file CNER.h.

BytesPtr castor::encoding::CNER::decBytes ( size_t  length  )  [inline, virtual]

Implements castor::Decoder.

Definition at line 424 of file CNER.h.

double castor::encoding::CNER::decDouble (  )  [inline, virtual]

Implements castor::Decoder.

Definition at line 402 of file CNER.h.

float castor::encoding::CNER::decFloat (  )  [inline, virtual]

Implements castor::Decoder.

Definition at line 391 of file CNER.h.

short castor::encoding::CNER::decInt16 (  )  [inline, virtual]

Implements castor::Decoder.

Definition at line 355 of file CNER.h.

long castor::encoding::CNER::decInt32 (  )  [inline, virtual]

Implements castor::Decoder.

Definition at line 367 of file CNER.h.

long long castor::encoding::CNER::decInt64 (  )  [inline, virtual]

Implements castor::Decoder.

Definition at line 379 of file CNER.h.

char castor::encoding::CNER::decInt8 (  )  [inline, virtual]

Implements castor::Decoder.

Definition at line 345 of file CNER.h.

size_t castor::encoding::CNER::decLength (  )  [inline, virtual]

Implements castor::Decoder.

Definition at line 313 of file CNER.h.

std::string castor::encoding::CNER::decString (  )  [inline, virtual]

Implements castor::Decoder.

Definition at line 408 of file CNER.h.

unsigned short castor::encoding::CNER::decUInt16 (  )  [inline, virtual]

Implements castor::Decoder.

Definition at line 361 of file CNER.h.

unsigned long castor::encoding::CNER::decUInt32 (  )  [inline, virtual]

Implements castor::Decoder.

Definition at line 373 of file CNER.h.

unsigned long long castor::encoding::CNER::decUInt64 (  )  [inline, virtual]

Implements castor::Decoder.

Definition at line 385 of file CNER.h.

unsigned char castor::encoding::CNER::decUInt8 (  )  [inline, virtual]

Implements castor::Decoder.

Definition at line 350 of file CNER.h.

void castor::encoding::CNER::encAddress ( const castor::net::NetAddress x  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 284 of file CNER.h.

void castor::encoding::CNER::encBool ( bool  x  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 227 of file CNER.h.

void castor::encoding::CNER::encBytes ( const char *  x,
size_t  offset,
size_t  length 
) [inline, virtual]

Implements castor::Encoder.

Definition at line 309 of file CNER.h.

void castor::encoding::CNER::encBytes ( const char *  x,
size_t  length 
) [inline, virtual]

Implements castor::Encoder.

Definition at line 305 of file CNER.h.

void castor::encoding::CNER::encBytes ( const Bytes x,
size_t  offset,
size_t  length 
) [inline, virtual]

Implements castor::Encoder.

Definition at line 296 of file CNER.h.

void castor::encoding::CNER::encBytes ( const Bytes x  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 292 of file CNER.h.

void castor::encoding::CNER::encDouble ( double  x  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 273 of file CNER.h.

void castor::encoding::CNER::encFloat ( float  x  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 266 of file CNER.h.

void castor::encoding::CNER::encInt16 ( short  x  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 242 of file CNER.h.

void castor::encoding::CNER::encInt32 ( long  x  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 250 of file CNER.h.

void castor::encoding::CNER::encInt64 ( long long  x  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 258 of file CNER.h.

void castor::encoding::CNER::encInt8 ( char  x  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 232 of file CNER.h.

void castor::encoding::CNER::encLength ( size_t  x  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 203 of file CNER.h.

void castor::encoding::CNER::encString ( const std::string  x  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 278 of file CNER.h.

void castor::encoding::CNER::encUInt16 ( unsigned short  x  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 246 of file CNER.h.

void castor::encoding::CNER::encUInt32 ( unsigned long  x  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 254 of file CNER.h.

void castor::encoding::CNER::encUInt64 ( unsigned long long  x  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 262 of file CNER.h.

void castor::encoding::CNER::encUInt8 ( unsigned char  x  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 237 of file CNER.h.

const char* castor::encoding::CNER::getBuffer (  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 153 of file CNER.h.

BytesPtr castor::encoding::CNER::getBytes (  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 157 of file CNER.h.

size_t castor::encoding::CNER::getLength (  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 123 of file CNER.h.

size_t castor::encoding::CNER::getPosition (  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 147 of file CNER.h.

void castor::encoding::CNER::mark (  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 162 of file CNER.h.

void castor::encoding::CNER::readInternal ( char *  data,
size_t  length,
bool  ignoreEndian = false 
) [inline, private]

Definition at line 47 of file CNER.h.

void castor::encoding::CNER::reset (  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 183 of file CNER.h.

void castor::encoding::CNER::rollback (  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 172 of file CNER.h.

void castor::encoding::CNER::seek ( long  offset  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 195 of file CNER.h.

void castor::encoding::CNER::switchEndianness ( bool  yes  )  [inline, virtual]

Implements castor::Encoder.

Definition at line 119 of file CNER.h.

void castor::encoding::CNER::writeInternal ( const char *  data,
size_t  length,
bool  ignoreEndian = false 
) [inline, private]

Definition at line 22 of file CNER.h.


Member Data Documentation

std::stringstream castor::encoding::CNER::buffer [private]

Definition at line 13 of file CNER.h.

Definition at line 15 of file CNER.h.

Definition at line 20 of file CNER.h.

Definition at line 17 of file CNER.h.

Definition at line 18 of file CNER.h.

enum { ... } castor::encoding::CNER::mode [private]

The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


Castor
Author(s): Carpe Noctem
autogenerated on Fri Mar 1 14:41:52 2013