#include <GContainers.h>
Inheritance diagram for GBytePipe:

Public Member Functions | |
| GBytePipe (int PreAlloc=0) | |
| Constructor. | |
| virtual | ~GBytePipe () |
| Desructor. | |
| virtual bool | IsEmpty () |
| Returns true if the container is empty. | |
| virtual void | Empty () |
| Empties the container freeing any memory used. | |
| virtual void * | New (int AddBytes=0) |
| virtual int | Peek (uchar *Ptr, int Size) |
| int64 | GetSize () |
| Gets the total bytes in the container. | |
| int | Read (void *Buffer, int Size, int Flags=0) |
| Reads bytes off the start of the container. | |
| int | Write (void *Buffer, int Size, int Flags=0) |
| Writes bytes to the end of the container. | |
| int | Pop (short &i) |
| Reads a 2 byte integer from the start. | |
| int | Pop (int &i) |
| Reads a 4 byte integer from the start. | |
| int | Pop (double &i) |
| Reads a double from the start. | |
| int | Push (short i) |
| Writes a 2 byte int to the end. | |
| int | Push (int i) |
| Writes a 2 byte int to the end. | |
| int | Push (double i) |
| Writes a double to the end. | |
Allows data to be buffered in separate memory blocks and then written to a continuous block for processing. Works as a first in first out que. You can (and should) provide a suitable PreAlloc size to the constructor. This can reduce the number of blocks of memory being used (and their associated alloc/free time and tracking overhead) in high volume situations.
|
|
Constructor.
|
|
|
Returns a dynamically allocated block that contains all the data in the container in a continuous block.
|
|
||||||||||||
|
Returns data from the start of the container without removing it from the que.
|
1.4.1