Essentia  2.1-beta6-dev
MultiRateBuffer< T > Class Template Referenceabstract

#include <multiratebuffer.h>

Inheritance diagram for MultiRateBuffer< T >:
PhantomBuffer< T >

Public Member Functions

virtual ~MultiRateBuffer ()
 
virtual void setBufferType (BufferUsage::BufferUsageType type)=0
 
virtual BufferInfo bufferInfo () const =0
 
virtual void setBufferInfo (const BufferInfo &info)=0
 
virtual ReaderID addReader (bool startFromZero=false)=0
 
virtual void removeReader (ReaderID id)=0
 
virtual int numberReaders () const =0
 
virtual bool acquireForRead (ReaderID id, int requested)=0
 
virtual void releaseForRead (ReaderID id, int released)=0
 
virtual bool acquireForWrite (int requested)=0
 
virtual void releaseForWrite (int released)=0
 
virtual int availableForRead (ReaderID id) const =0
 
virtual int availableForWrite (bool contiguous=true) const =0
 
virtual int totalTokensRead (ReaderID id) const =0
 
virtual int totalTokensWritten () const =0
 
virtual const T & lastTokenProduced () const =0
 
void readerConsume (ReaderID id, int requested)
 
void readerProduce (ReaderID id, int released)
 
void writerConsume (int requested)
 
void writerProduce (int released)
 
virtual const std::vector< T > & readView (ReaderID id) const =0
 
virtual std::vector< T > & writeView ()=0
 
virtual void reset ()=0
 
virtual void resize (int size, int phantomSize)=0
 

Constructor & Destructor Documentation

◆ ~MultiRateBuffer()

virtual ~MultiRateBuffer ( )
inlinevirtual

Member Function Documentation

◆ acquireForRead()

virtual bool acquireForRead ( ReaderID  id,
int  requested 
)
pure virtual

◆ acquireForWrite()

virtual bool acquireForWrite ( int  requested)
pure virtual

◆ addReader()

virtual ReaderID addReader ( bool  startFromZero = false)
pure virtual

◆ availableForRead()

virtual int availableForRead ( ReaderID  id) const
pure virtual

◆ availableForWrite()

virtual int availableForWrite ( bool  contiguous = true) const
pure virtual

◆ bufferInfo()

virtual BufferInfo bufferInfo ( ) const
pure virtual

Implemented in PhantomBuffer< T >.

Referenced by Source< TokenType >::bufferInfo().

◆ lastTokenProduced()

virtual const T& lastTokenProduced ( ) const
pure virtual

◆ numberReaders()

virtual int numberReaders ( ) const
pure virtual

Implemented in PhantomBuffer< T >.

◆ readerConsume()

void readerConsume ( ReaderID  id,
int  requested 
)
inline

◆ readerProduce()

void readerProduce ( ReaderID  id,
int  released 
)
inline

◆ readView()

virtual const std::vector<T>& readView ( ReaderID  id) const
pure virtual

◆ releaseForRead()

virtual void releaseForRead ( ReaderID  id,
int  released 
)
pure virtual

◆ releaseForWrite()

virtual void releaseForWrite ( int  released)
pure virtual

◆ removeReader()

virtual void removeReader ( ReaderID  id)
pure virtual

◆ reset()

virtual void reset ( )
pure virtual

Implemented in PhantomBuffer< T >.

Referenced by Source< TokenType >::reset().

◆ resize()

virtual void resize ( int  size,
int  phantomSize 
)
pure virtual

Implemented in PhantomBuffer< T >.

◆ setBufferInfo()

virtual void setBufferInfo ( const BufferInfo info)
pure virtual

◆ setBufferType()

virtual void setBufferType ( BufferUsage::BufferUsageType  type)
pure virtual

◆ totalTokensRead()

virtual int totalTokensRead ( ReaderID  id) const
pure virtual

Implemented in PhantomBuffer< T >.

◆ totalTokensWritten()

virtual int totalTokensWritten ( ) const
pure virtual

◆ writerConsume()

void writerConsume ( int  requested)
inline

◆ writerProduce()

void writerProduce ( int  released)
inline

◆ writeView()

virtual std::vector<T>& writeView ( )
pure virtual

The documentation for this class was generated from the following file: