PUMA Library Reference Manual
Puma::Sink Class Referenceabstract

#include <Puma/Sink.h>

+ Inheritance diagram for Puma::Sink:

Description

Output sink interface.

Warning
This class is not used and may disappear without notice.

Public Member Functions

virtual ~Sink ()
 Destructor. More...
 
virtual int write (const char *buffer, int n)=0
 Write n bytes from the given buffer into the sink. More...
 
virtual bool full ()
 Check if the output sink is full. More...
 

Constructor & Destructor Documentation

◆ ~Sink()

virtual Puma::Sink::~Sink ( )
inlinevirtual

Destructor.

Member Function Documentation

◆ full()

virtual bool Puma::Sink::full ( )
inlinevirtual

Check if the output sink is full.

Returns
This default implementation always returns false.

Reimplemented in Puma::Pipe.

◆ write()

virtual int Puma::Sink::write ( const char *  buffer,
int  n 
)
pure virtual

Write n bytes from the given buffer into the sink.

Parameters
bufferThe bytes to write.
nThe number of bytes to write.
Returns
The number of bytes written.

Implemented in Puma::Pipe, and Puma::TerminalSink.