Classes | Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
RTT::base::MultipleOutputsChannelElementBase Class Reference

#include <ChannelElementBase.hpp>

Inheritance diagram for RTT::base::MultipleOutputsChannelElementBase:
Inheritance graph
[legend]

Classes

struct  Output
 

Public Types

typedef std::list< OutputOutputs
 
typedef boost::intrusive_ptr< MultipleOutputsChannelElementBaseshared_ptr
 
- Public Types inherited from RTT::base::ChannelElementBase
typedef boost::intrusive_ptr< ChannelElementBaseshared_ptr
 

Public Member Functions

virtual bool channelReady (ChannelElementBase::shared_ptr const &caller, ConnPolicy const &policy, internal::ConnID *conn_id=0)
 
virtual bool connected ()
 
virtual bool disconnect (ChannelElementBase::shared_ptr const &channel, bool forward=false)
 
 MultipleOutputsChannelElementBase ()
 
virtual bool signal ()
 
- Public Member Functions inherited from RTT::base::ChannelElementBase
 ChannelElementBase ()
 
virtual void clear ()
 
virtual bool connectFrom (ChannelElementBase::shared_ptr const &input)
 
virtual bool connectTo (ChannelElementBase::shared_ptr const &output, bool mandatory=true)
 
virtual void disconnect (bool forward)
 
virtual const ConnPolicygetConnPolicy () const
 
virtual std::string getElementName () const
 
shared_ptr getInput ()
 
virtual shared_ptr getInputEndPoint ()
 
virtual std::string getLocalURI () const
 
shared_ptr getOutput ()
 
virtual shared_ptr getOutputEndPoint ()
 
virtual PortInterfacegetPort () const
 
virtual std::string getRemoteURI () const
 
virtual bool inputReady (ChannelElementBase::shared_ptr const &caller)
 
virtual bool isRemoteElement () const
 
template<typename T >
ChannelElement< T > * narrow ()
 
RTT_DEPRECATED void setInput (const ChannelElementBase::shared_ptr &input)
 
RTT_DEPRECATED void setOutput (const ChannelElementBase::shared_ptr &output)
 
virtual bool signalFrom (ChannelElementBase *)
 
virtual ~ChannelElementBase ()
 

Protected Member Functions

virtual bool addOutput (ChannelElementBase::shared_ptr const &output, bool mandatory=true)
 
void removeDisconnectedOutputs ()
 
virtual void removeOutput (ChannelElementBase::shared_ptr const &output)
 
- Protected Member Functions inherited from RTT::base::ChannelElementBase
virtual bool addInput (shared_ptr const &input)
 
void deref ()
 
void ref ()
 
virtual void removeInput (shared_ptr const &input)
 

Protected Attributes

Outputs outputs
 
RTT::os::SharedMutex outputs_lock
 
- Protected Attributes inherited from RTT::base::ChannelElementBase
shared_ptr input
 
RTT::os::SharedMutex input_lock
 
shared_ptr output
 
RTT::os::SharedMutex output_lock
 

Additional Inherited Members

- Static Public Member Functions inherited from RTT::base::ChannelElementBase
template<typename T >
static ChannelElement< T > * narrow (ChannelElementBase *e)
 

Detailed Description

ChannelElementBase variant with multiple output channels.

Definition at line 392 of file ChannelElementBase.hpp.

Member Typedef Documentation

Definition at line 403 of file ChannelElementBase.hpp.

Definition at line 395 of file ChannelElementBase.hpp.

Constructor & Destructor Documentation

MultipleOutputsChannelElementBase::MultipleOutputsChannelElementBase ( )

Definition at line 321 of file ChannelInterface.cpp.

Member Function Documentation

bool MultipleOutputsChannelElementBase::addOutput ( ChannelElementBase::shared_ptr const &  output,
bool  mandatory = true 
)
protectedvirtual

Sets the new output channel element of this element or adds a channel to the outputs list.

Parameters
outputthe next element in chain.
mandatorywhether the added output is mandatory for a write to succeed
Returns
true if the output was set or false if this element does not support multiple outputs and the output is already set.

Reimplemented from RTT::base::ChannelElementBase.

Definition at line 335 of file ChannelInterface.cpp.

bool MultipleOutputsChannelElementBase::channelReady ( ChannelElementBase::shared_ptr const &  caller,
ConnPolicy const &  policy,
internal::ConnID conn_id = 0 
)
virtual

Overridden implementation of ChannelElementBase::channelReady() which forwards the signal to all outputs.

Reimplemented from RTT::base::ChannelElementBase.

Definition at line 365 of file ChannelInterface.cpp.

bool MultipleOutputsChannelElementBase::connected ( )
virtual

Returns true, if this channel element has at least one output, independent of whether is has an input connection or not.

Reimplemented from RTT::base::ChannelElementBase.

Reimplemented in RTT::base::MultipleInputsMultipleOutputsChannelElementBase.

Definition at line 350 of file ChannelInterface.cpp.

bool MultipleOutputsChannelElementBase::disconnect ( ChannelElementBase::shared_ptr const &  channel,
bool  forward = false 
)
virtual
void MultipleOutputsChannelElementBase::removeDisconnectedOutputs ( )
protected

Iterate over all output channels and remove the ones that have been marked as disconnected (after a failed write() or data_sample() call).

Definition at line 419 of file ChannelInterface.cpp.

void MultipleOutputsChannelElementBase::removeOutput ( ChannelElementBase::shared_ptr const &  output)
protectedvirtual

Remove an output from the outputs list.

Parameters
outputthe element to be removed

Reimplemented from RTT::base::ChannelElementBase.

Definition at line 345 of file ChannelInterface.cpp.

bool MultipleOutputsChannelElementBase::signal ( )
virtual

Overridden implementation of ChannelElementBase::signal() which forwards the signal to all outputs.

Reimplemented from RTT::base::ChannelElementBase.

Definition at line 356 of file ChannelInterface.cpp.

Member Data Documentation

Outputs RTT::base::MultipleOutputsChannelElementBase::outputs
protected

Definition at line 406 of file ChannelElementBase.hpp.

RTT::os::SharedMutex RTT::base::MultipleOutputsChannelElementBase::outputs_lock
mutableprotected

Definition at line 407 of file ChannelElementBase.hpp.


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


rtt
Author(s): RTT Developers
autogenerated on Fri Oct 25 2019 03:59:46