Oolite 1.91.0.7646-241128-10e222e
|
#include "OOTCPStreamDecoderAbstractionLayer.h"
Go to the source code of this file.
Typedefs | |
typedef struct OOTCPStreamDecoder * | OOTCPStreamDecoderRef |
typedef void(* | OOTCPStreamDecoderPacketCallback) (void *cbInfo, OOALStringRef packetType, OOALDictionaryRef packet) |
typedef void(* | OOTCPStreamDecoderErrorCallback) (void *cbInfo, OOALStringRef errorDesc) |
typedef void(* | OOTCPStreamDecoderFinalizeCallback) (void *cbInfo) |
Functions | |
OOTCPStreamDecoderRef | OOTCPStreamDecoderCreate (OOTCPStreamDecoderPacketCallback packetCB, OOTCPStreamDecoderErrorCallback errorCB, OOTCPStreamDecoderFinalizeCallback finalizeCB, void *cbInfo) |
void | OOTCPStreamDecoderDestroy (OOTCPStreamDecoderRef decoder) |
void | OOTCPStreamDecoderReceiveData (OOTCPStreamDecoderRef decoder, OOALDataRef data) |
void | OOTCPStreamDecoderReceiveBytes (OOTCPStreamDecoderRef decoder, const void *bytes, size_t length) |
typedef void(* OOTCPStreamDecoderErrorCallback) (void *cbInfo, OOALStringRef errorDesc) |
Definition at line 41 of file OOTCPStreamDecoder.h.
typedef void(* OOTCPStreamDecoderFinalizeCallback) (void *cbInfo) |
Definition at line 42 of file OOTCPStreamDecoder.h.
typedef void(* OOTCPStreamDecoderPacketCallback) (void *cbInfo, OOALStringRef packetType, OOALDictionaryRef packet) |
Definition at line 40 of file OOTCPStreamDecoder.h.
typedef struct OOTCPStreamDecoder* OOTCPStreamDecoderRef |
Definition at line 38 of file OOTCPStreamDecoder.h.
OOTCPStreamDecoderRef OOTCPStreamDecoderCreate | ( | OOTCPStreamDecoderPacketCallback | packetCB, |
OOTCPStreamDecoderErrorCallback | errorCB, | ||
OOTCPStreamDecoderFinalizeCallback | finalizeCB, | ||
void * | cbInfo ) |
Definition at line 64 of file OOTCPStreamDecoder.c.
References OOTCPStreamDecoder::cbInfo, OOTCPStreamDecoder::Error, OOTCPStreamDecoder::Finalize, OOTCPStreamDecoder::headerSpaceUsed, OOTCPStreamDecoder::nextPacketData, OOTCPStreamDecoder::nextSize, and OOTCPStreamDecoder::Packet.
void OOTCPStreamDecoderDestroy | ( | OOTCPStreamDecoderRef | decoder | ) |
Definition at line 85 of file OOTCPStreamDecoder.c.
References OOTCPStreamDecoder::cbInfo, OOTCPStreamDecoder::Finalize, OOTCPStreamDecoder::nextPacketData, and OOALRelease().
void OOTCPStreamDecoderReceiveBytes | ( | OOTCPStreamDecoderRef | decoder, |
const void * | bytes, | ||
size_t | length ) |
Definition at line 112 of file OOTCPStreamDecoder.c.
References Error(), OOTCPStreamDecoder::header, OOTCPStreamDecoder::headerSpaceUsed, OOTCPStreamDecoder::nextPacketData, OOTCPStreamDecoder::nextSize, OOALCreateAutoreleasePool(), OOALDataCreateMutable(), OOALDestroyAutoreleasePool, OOALMutableDataAppendBytes(), OOALRelease(), OOALSTR, and PacketReady().
Referenced by OOTCPStreamDecoderReceiveData().
void OOTCPStreamDecoderReceiveData | ( | OOTCPStreamDecoderRef | decoder, |
OOALDataRef | data ) |
Definition at line 104 of file OOTCPStreamDecoder.c.
References OOALDataGetBytePtr(), OOALDataGetLength(), and OOTCPStreamDecoderReceiveBytes().