Cinder  0.9.1
Public Member Functions | List of all members
cinder::signals::ScopedConnection Class Reference

#include <Signals.h>

Inherits cinder::signals::Connection, and cinder::Noncopyable.

Public Member Functions

 ScopedConnection ()
 
 ~ScopedConnection ()
 
 ScopedConnection (const Connection &other)
 
 ScopedConnection (ScopedConnection &&other)
 
 ScopedConnection (Connection &&other)
 
ScopedConnectionoperator= (const Connection &rhs)
 
ScopedConnectionoperator= (ScopedConnection &&rhs)
 
bool disconnect ()
 
bool isConnected () const
 
void enable ()
 
void disable ()
 
bool isEnabled () const
 

Detailed Description

ScopedConnection can be captured from Signal::connect() to limit the connection lifetime to the current scope, after which Connection::disconnect() will be called.

Constructor & Destructor Documentation

cinder::signals::ScopedConnection::ScopedConnection ( )
cinder::signals::ScopedConnection::~ScopedConnection ( )
cinder::signals::ScopedConnection::ScopedConnection ( const Connection other)
cinder::signals::ScopedConnection::ScopedConnection ( ScopedConnection &&  other)
cinder::signals::ScopedConnection::ScopedConnection ( Connection &&  other)

Member Function Documentation

ScopedConnection & cinder::signals::ScopedConnection::operator= ( const Connection rhs)
ScopedConnection & cinder::signals::ScopedConnection::operator= ( ScopedConnection &&  rhs)
bool cinder::signals::Connection::disconnect ( )
inherited

Disconnects this Connection from the callback chain. return true if a disconnection was made, false otherwise.

bool cinder::signals::Connection::isConnected ( ) const
inherited

Returns whether or not this Connection is still connected to the callback chain.

void cinder::signals::Connection::enable ( )
inherited

Enable calling the function linked to this Connection. Does not affect the callback chain. Default is enabled.

void cinder::signals::Connection::disable ( )
inherited

Disable calling the function linked to this Connection. Does not affect the callback chain.

bool cinder::signals::Connection::isEnabled ( ) const
inherited

Returns true if the linked function will be called as part of the callback chain. Default is enabled.


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