stromx  0.7.0
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Pages
Public Member Functions | List of all members
stromx::runtime::Description Class Reference

Description of a connector. More...

#include <Description.h>

Inheritance diagram for stromx::runtime::Description:
stromx::runtime::DescriptionBase stromx::runtime::MatrixDescription

Public Member Functions

 Description (const unsigned int id, const VariantHandle &variant)
 
unsigned int operatorThread () const
 
void setOperatorThread (const unsigned int operatorThread)
 
- Public Member Functions inherited from stromx::runtime::DescriptionBase
 DescriptionBase (const unsigned int id, const VariantHandle &variant)
 
const std::string & title () const
 
unsigned int id () const
 
const VariantHandlevariant () const
 
void setTitle (const std::string &title)
 
const VariantHandlevisualization () const
 
void setVisualization (const VariantHandle &visualization)
 
virtual const Datamax () const
 
virtual const Datamin () const
 
virtual const Datastep () const
 
virtual const std::vector
< EnumDescription > & 
descriptions () const
 
virtual unsigned int rows () const
 
virtual unsigned int cols () const
 

Detailed Description

Description of a connector.

In addition to the information stored in the parent class descriptions store threading properties of connectors.

Constructor & Destructor Documentation

stromx::runtime::Description::Description ( const unsigned int  id,
const VariantHandle variant 
)
inline

Constructs a description.

Member Function Documentation

unsigned int stromx::runtime::Description::operatorThread ( ) const
inline

Returns the operator thread of this connector.

See also
setOperatorThread()
void stromx::runtime::Description::setOperatorThread ( const unsigned int  operatorThread)
inline

Sets the operator thread of this connector.

The operator thread of a connector specifies which thread can be assigned to the connector in the context of the operator the connector belongs to. If e.g. an operator has one input and one output and produces one data object at the output if and only if one data object is given to the input than it is safe to assign the same operator thread to the input and the output. I.e. the the operator threads of both the input and the output can have their default values 0.

If the operator produces one data object at the output only after it has received a couple of input objects at the input then a thread handling the input and the output would dead-lock waiting for the output after the input has been set. Setting the operator thread values of the input and the output tells an algorithm which automatically assigns threads to the stream that this situation must be avoided.


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