Orocos Real-Time Toolkit  2.8.3
Public Member Functions | List of all members
RTT::types::BinaryOperator< function > Class Template Reference

An operator which reads a two DataSources and returns a modified result. More...

#include <rtt/types/OperatorTypes.hpp>

Inheritance diagram for RTT::types::BinaryOperator< function >:
RTT::types::BinaryOp

Public Member Functions

 BinaryOperator (const char *op, function f)
 
internal::DataSource< result_t > * build (const std::string &op, base::DataSourceBase *a, base::DataSourceBase *b)
 If op is the operator you are responsible for, and if the argument internal::DataSource's are of the correct type, then return an appropriate internal::DataSource ( i.e. More...
 
bool isExactMatch (const std::string &op, base::DataSourceBase *a, base::DataSourceBase *b)
 Returns true if this binary operator matches op, and a and b are the exact types this operator expects. More...
 

Detailed Description

template<typename function>
class RTT::types::BinaryOperator< function >

An operator which reads a two DataSources and returns a modified result.

Definition at line 84 of file OperatorTypes.hpp.

Constructor & Destructor Documentation

template<typename function>
RTT::types::BinaryOperator< function >::BinaryOperator ( const char *  op,
function  f 
)
inline

Definition at line 93 of file OperatorTypes.hpp.

Member Function Documentation

template<typename function>
internal::DataSource<result_t>* RTT::types::BinaryOperator< function >::build ( const std::string &  op,
base::DataSourceBase a,
base::DataSourceBase b 
)
inlinevirtual

If op is the operator you are responsible for, and if the argument internal::DataSource's are of the correct type, then return an appropriate internal::DataSource ( i.e.

a internal::DataSource that will apply a certain operation on the values it gets from its argument DataSources, and will return that value ). Otherwise, return 0.

Implements RTT::types::BinaryOp.

Definition at line 97 of file OperatorTypes.hpp.

References RTT::types::TypeInfo::convert(), RTT::internal::DataSourceTypeInfo< T >::getTypeInfo(), and RTT::base::DataSourceBase::getTypeInfo().

template<typename function>
bool RTT::types::BinaryOperator< function >::isExactMatch ( const std::string &  op,
base::DataSourceBase a,
base::DataSourceBase b 
)
inlinevirtual

Returns true if this binary operator matches op, and a and b are the exact types this operator expects.

Implements RTT::types::BinaryOp.

Definition at line 115 of file OperatorTypes.hpp.

References RTT::internal::DataSourceTypeInfo< T >::getTypeInfo(), and RTT::base::DataSourceBase::getTypeInfo().


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