stromx  0.8.0
Public Member Functions | Protected Member Functions | List of all members
stromx::runtime::ConnectorDescription Class Reference

Description of a connector. More...

#include <ConnectorDescription.h>

Inheritance diagram for stromx::runtime::ConnectorDescription:
stromx::runtime::Description stromx::runtime::Input stromx::runtime::Output

Public Member Functions

virtual void setRows (const unsigned int value)
 
virtual void setCols (const unsigned int value)
 
unsigned int operatorThread () const
 
void setOperatorThread (const unsigned int operatorThread)
 
Type defaultType () const
 
UpdateBehavior defaultBehavior () const
 
void setDefaultType (const Type type, const UpdateBehavior behavior=PERSISTENT)
 
virtual unsigned int rows () const
 
virtual unsigned int cols () const
 
- Public Member Functions inherited from stromx::runtime::Description
 Description (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 Type originalType () const
 
virtual Type currentType () const
 

Protected Member Functions

 ConnectorDescription (const unsigned int id, const VariantHandle &variant, const Type defaultType)
 

Additional Inherited Members

- Public Types inherited from stromx::runtime::Description
enum  Type { NO_TYPE, PARAMETER, INPUT, OUTPUT }
 
enum  UpdateBehavior { PERSISTENT, PUSH, PULL, INTERNAL }
 

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

§ ConnectorDescription()

stromx::runtime::ConnectorDescription::ConnectorDescription ( const unsigned int  id,
const VariantHandle variant,
const Type  defaultType 
)
inlineprotected

Constructs a description.

Member Function Documentation

§ cols()

virtual unsigned int stromx::runtime::ConnectorDescription::cols ( ) const
inlinevirtual

Returns the required number of columns of a matrix parameters. Returns 0 if any number of columns is possible.

Reimplemented from stromx::runtime::Description.

§ defaultBehavior()

UpdateBehavior stromx::runtime::ConnectorDescription::defaultBehavior ( ) const
inline

Input and output connectors can be configured to act as operator parameters. Such a connector is listed as an operator parameter. If the default type of a connectors is Description::PARAMETER its update behavior will be as set by this function.

§ defaultType()

Type stromx::runtime::ConnectorDescription::defaultType ( ) const
inline

Input and output connectors can be configured to act as operator parameters. Such a connector is listed as an operator parameter. If the default type of a connectors is Description::PARAMETER it will be a parameter upon the first initialization of the operator. It can however be converted back to a connector by the client.

§ operatorThread()

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

Returns the operator thread of this connector.

See also
setOperatorThread()

§ rows()

virtual unsigned int stromx::runtime::ConnectorDescription::rows ( ) const
inlinevirtual

Returns the required number of rows of a matrix parameters. Returns 0 if any number of rows is possible.

Reimplemented from stromx::runtime::Description.

§ setCols()

virtual void stromx::runtime::ConnectorDescription::setCols ( const unsigned int  value)
inlinevirtual

Sets the required number of matrix rows of this parameter. Passing 0 for value allows any number of rows.

§ setDefaultType()

void stromx::runtime::ConnectorDescription::setDefaultType ( const Type  type,
const UpdateBehavior  behavior = PERSISTENT 
)
inline

Sets the default type. If the default type is Description::PARAMETER, the update behavior can further be specified.

See also
defaultType

§ setOperatorThread()

void stromx::runtime::ConnectorDescription::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.

§ setRows()

virtual void stromx::runtime::ConnectorDescription::setRows ( const unsigned int  value)
inlinevirtual

Sets the required number of matrix rows of this parameter. Passing 0 for value allows any number of rows.


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