Essentia  2.1-beta6-dev
SinkProxy< TokenType > Class Template Reference

#include <sinkproxy.h>

Inheritance diagram for SinkProxy< TokenType >:
SinkProxyBase SinkBase Connector TypeProxy StreamConnector

Public Member Functions

 SinkProxy (Algorithm *parent=0, const std::string &name="unnamed")
 
 SinkProxy (const std::string &name)
 
const MultiRateBuffer< TokenType > & buffer () const
 
MultiRateBuffer< TokenType > & buffer ()
 
void connect (SourceBase &source)
 
void disconnect (SourceBase &source)
 
virtual const void * getTokens () const
 
virtual const void * getFirstToken () const
 
virtual int available () const
 
virtual void reset ()
 
- Public Member Functions inherited from SinkProxyBase
 SinkProxyBase (Algorithm *parent=0, const std::string &name="unnamed")
 
 SinkProxyBase (const std::string &name)
 
 ~SinkProxyBase ()
 
const void * buffer () const
 
void * buffer ()
 
void setId (ReaderID id)
 
void setSource (SourceBase *source)
 
void acquire ()
 
virtual bool acquire (int n)
 
virtual int acquireSize () const
 
void release ()
 
virtual void release (int n)
 
virtual int releaseSize () const
 
void updateProxiedSink ()
 
void detach ()
 
- Public Member Functions inherited from SinkBase
 SinkBase (Algorithm *parent=0, const std::string &name="unnamed")
 
 SinkBase (const std::string &name)
 
 ~SinkBase ()
 
const SourceBasesource () const
 
SourceBasesource ()
 
ReaderID id () const
 
- Public Member Functions inherited from Connector
 Connector (Algorithm *parent=0, const std::string &name="Unnamed")
 
 Connector (const std::string &name)
 
const Algorithmparent () const
 
Algorithmparent ()
 
void setParent (Algorithm *parent)
 
std::string parentName () const
 
std::string fullName () const
 
- Public Member Functions inherited from TypeProxy
 TypeProxy ()
 
 TypeProxy (const std::string &name)
 
virtual ~TypeProxy ()
 
const std::string & name () const
 
void setName (const std::string &name)
 
void checkType (const std::type_info &received, const std::type_info &expected) const
 
template<typename Type >
void checkType () const
 
void checkSameTypeAs (const TypeProxy &obj) const
 
void checkVectorSameTypeAs (const TypeProxy &obj) const
 
- Public Member Functions inherited from StreamConnector
 StreamConnector ()
 
virtual ~StreamConnector ()
 
bool acquire ()
 
void release ()
 
virtual void setAcquireSize (int n)
 
virtual void setReleaseSize (int n)
 

Private Member Functions

virtual const std::type_info & typeInfo () const
 
virtual const std::type_info & vectorTypeInfo () const
 

Additional Inherited Members

- Protected Member Functions inherited from SinkProxyBase
void attach (SinkBase *sink)
 
void detach (SinkBase *sink)
 
- Protected Member Functions inherited from SinkBase
void attachProxy (SinkProxyBase *sproxy)
 
void detachProxy (SinkProxyBase *sproxy)
 
- Protected Attributes inherited from SinkProxyBase
SinkBase_proxiedSink
 
- Protected Attributes inherited from SinkBase
SourceBase_source
 
ReaderID _id
 
SinkProxyBase_sproxy
 
- Protected Attributes inherited from Connector
Algorithm_parent
 
- Protected Attributes inherited from TypeProxy
std::string _name
 
- Protected Attributes inherited from StreamConnector
int _acquireSize
 
int _releaseSize
 

Constructor & Destructor Documentation

◆ SinkProxy() [1/2]

SinkProxy ( Algorithm parent = 0,
const std::string &  name = "unnamed" 
)
inline

◆ SinkProxy() [2/2]

SinkProxy ( const std::string &  name)
inline

Member Function Documentation

◆ available()

virtual int available ( ) const
inlinevirtual

Returns how many tokens are available in the stream.

Implements StreamConnector.

References SinkBase::_id, MultiRateBuffer< T >::availableForRead(), and SinkProxy< TokenType >::buffer().

◆ buffer() [1/2]

MultiRateBuffer<TokenType>& buffer ( )
inline

◆ buffer() [2/2]

const MultiRateBuffer<TokenType>& buffer ( ) const
inline

◆ connect()

◆ disconnect()

void disconnect ( SourceBase source)
inlinevirtual

◆ getFirstToken()

virtual const void* getFirstToken ( ) const
inlinevirtual

Implements SinkBase.

References Connector::fullName().

◆ getTokens()

virtual const void* getTokens ( ) const
inlinevirtual

Implements SinkBase.

References Connector::fullName().

◆ reset()

virtual void reset ( )
inlinevirtual

Resets the state of this StreamConnector

Implements StreamConnector.

◆ typeInfo()

virtual const std::type_info& typeInfo ( ) const
inlineprivatevirtual

Implements TypeProxy.

◆ vectorTypeInfo()

virtual const std::type_info& vectorTypeInfo ( ) const
inlineprivatevirtual

Implements TypeProxy.


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