5 inline char * RingBuffer::GetMessageHead(
void)
7 return _Buffer+_StartPos;
12 inline char * RingBuffer::GetBufferOpen(
void)
14 return _Buffer+_EndPos;
19 inline void RingBuffer::ForceWindowSlide(
void)
22 if(len > 0 && _StartPos != 0)
24 memmove(_Buffer,GetMessageHead(),len);
34 return _EndPos - _StartPos;
59 inline RingBuffer::RingBuffer(
size_t in_size) :
MemBuffer(in_size)
69 if(_StartPos == _EndPos)
89 if(_StartPos == _EndPos)
113 memcpy(GetBufferOpen(),data,len);
124 inline bool RingBuffer::PutFast(
const char * data,
size_t len)
127 memcpy(GetBufferOpen(),data,len);
142 memcpy(data,GetMessageHead(),len);
size_t GetBufferSize(void) const
Access to the BUffer Size Information.
size_t BufferAvailabe(void)
Will report amount of data that is contiguas that can be writen at the location returned by GetBuffer...
bool Get(char *data, size_t len)
will copy the data .
bool Put(const char *data, size_t len)
Adds Data to a ring Buffer Will do a compress if needed so pointers suplied by Get Call are no longer...
void FullCompress(void)
Force a compress of the data.
size_t AmountBuffered(void)
Will report the number of unread chars in buffer.
void ResetContent(void)
Throw away all inread information.
void Compress(void)
Try and do a intelegent compress of the data space the algorithem is really stupid right know.