Poco

class FIFOBufferStreamBuf

File Information

Library: Foundation
Package: Streams
Header: Poco/FIFOBufferStream.h

Description

This is the streambuf class used for reading from and writing to a FIFOBuffer. FIFOBuffer is enabled for emtpy/non-empty/full state transitions notifications.

Inheritance

Direct Base Classes: BufferedBidirectionalStreamBuf

All Base Classes: BufferedBidirectionalStreamBuf

Member Summary

Member Functions: fifoBuffer, readFromDevice, writeToDevice

Constructors

FIFOBufferStreamBuf

FIFOBufferStreamBuf();

Creates a FIFOBufferStreamBuf.

FIFOBufferStreamBuf

explicit FIFOBufferStreamBuf(
    FIFOBuffer & fifoBuffer
);

Creates a FIFOBufferStreamBuf and assigns the given buffer to it.

FIFOBufferStreamBuf

explicit FIFOBufferStreamBuf(
    std::size_t length
);

Creates a FIFOBufferStreamBuf of the given length.

FIFOBufferStreamBuf

FIFOBufferStreamBuf(
    char * pBuffer,
    std::size_t length
);

Creates a FIFOBufferStreamBuf and assigns the given buffer to it.

FIFOBufferStreamBuf

FIFOBufferStreamBuf(
    const char * pBuffer,
    std::size_t length
);

Creates a FIFOBufferStreamBuf and assigns the given buffer to it.

Destructor

~FIFOBufferStreamBuf

~FIFOBufferStreamBuf();

Destroys the FIFOBufferStreamBuf.

Member Functions

fifoBuffer inline

FIFOBuffer & fifoBuffer();

Returns the underlying FIFO buffer reference.

readFromDevice protected

int readFromDevice(
    char * buffer,
    std::streamsize length
);

writeToDevice protected

int writeToDevice(
    const char * buffer,
    std::streamsize length
);