21 #ifndef INCLUDE_OLA_IO_IOQUEUE_H_
22 #define INCLUDE_OLA_IO_IOQUEUE_H_
24 #include <ola/io/IOVecInterface.h>
25 #include <ola/io/InputBuffer.h>
26 #include <ola/io/OutputBuffer.h>
48 unsigned int Size()
const;
51 return m_blocks.empty();
55 void Write(
const uint8_t *data,
unsigned int length);
58 unsigned int Read(uint8_t *data,
unsigned int length);
59 unsigned int Read(std::string *output,
unsigned int length);
61 unsigned int Peek(uint8_t *data,
unsigned int length)
const;
65 void Pop(
unsigned int n);
81 void Dump(std::ostream *output);
84 typedef std::deque<class MemoryBlock*> BlockVector;
99 #endif // INCLUDE_OLA_IO_IOQUEUE_H_
unsigned int Size() const
Definition: IOQueue.cpp:67
Definition: OutputBuffer.h:36
~IOQueue()
Definition: IOQueue.cpp:56
Definition: IOVecInterface.h:36
const struct IOVec * AsIOVec(int *io_count) const
Definition: IOQueue.cpp:186
void AppendBlock(class MemoryBlock *block)
Definition: IOQueue.cpp:213
void Write(const uint8_t *data, unsigned int length)
Definition: IOQueue.cpp:82
void Clear()
Definition: IOQueue.cpp:229
Definition: IOVecInterface.h:53
A MemoryBlock encapsulates a chunk of memory. It's used by the IOQueue and IOStack classes...
Definition: MemoryBlock.h:41
void Dump(std::ostream *output)
Definition: IOQueue.cpp:243
The namespace containing all OLA symbols.
Definition: Credentials.cpp:44
unsigned int Peek(uint8_t *data, unsigned int length) const
Definition: IOQueue.cpp:147
unsigned int Read(uint8_t *data, unsigned int length)
Definition: IOQueue.cpp:103
MemoryBlockPool. This class is not thread safe.
Definition: MemoryBlockPool.h:35
void Pop(unsigned int n)
Definition: IOQueue.cpp:161
void AppendMove(IOQueue *other)
Move the contents of one IOQueue to another.
Definition: IOQueue.cpp:217
IOQueue()
IOQueue.
Definition: IOQueue.cpp:42