transformer
Public Member Functions | Protected Attributes | List of all members
transformer::TransformationElement Class Referenceabstract

#include <Transformer.hpp>

Inheritance diagram for transformer::TransformationElement:
transformer::DynamicTransformationElement transformer::InverseTransformationElement transformer::NonAlignedDynamicTransformationElement transformer::StaticTransformationElement

Public Member Functions

 TransformationElement (const std::string &sourceFrame, const std::string &targetFrame)
 
virtual ~TransformationElement ()
 
virtual bool getTransformation (const base::Time &atTime, bool doInterpolation, TransformationType &tr)=0
 
virtual void addTransformationChangedCallback (boost::function< void(const base::Time &ts)> callback)
 
virtual void clearTransformationChangedCallbacks ()
 
const std::string & getSourceFrame () const
 
const std::string & getTargetFrame () const
 

Protected Attributes

std::vector< boost::function
< void(const base::Time &ts)> > 
elementChangedCallbacks
 

Detailed Description

This is a base class, that represens an abstract transformation from sourceFrame to targetFrame.

Constructor & Destructor Documentation

transformer::TransformationElement::TransformationElement ( const std::string &  sourceFrame,
const std::string &  targetFrame 
)
inline
virtual transformer::TransformationElement::~TransformationElement ( )
inlinevirtual

Member Function Documentation

virtual void transformer::TransformationElement::addTransformationChangedCallback ( boost::function< void(const base::Time &ts)>  callback)
inlinevirtual

This function registers a callback, that should be called every time the TransformationElement changes its value.

Reimplemented in transformer::InverseTransformationElement.

virtual void transformer::TransformationElement::clearTransformationChangedCallbacks ( )
inlinevirtual

Removes all registered callbacks

const std::string& transformer::TransformationElement::getSourceFrame ( ) const
inline

returns the name of the source frame

const std::string& transformer::TransformationElement::getTargetFrame ( ) const
inline

returns the name of the target frame

virtual bool transformer::TransformationElement::getTransformation ( const base::Time &  atTime,
bool  doInterpolation,
TransformationType tr 
)
pure virtual

This method my be asked for a concrete transformation at a time X. On request this should should interpolate the transformation to match the given time better than the available data.

Note if no transformation is available getTransformation will return false

Implemented in transformer::InverseTransformationElement, transformer::DynamicTransformationElement, transformer::StaticTransformationElement, and transformer::NonAlignedDynamicTransformationElement.

Member Data Documentation

std::vector<boost::function<void (const base::Time &ts)> > transformer::TransformationElement::elementChangedCallbacks
protected

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