OMK::Iii::AverageT< Type > Class Template Reference

Convertor class which calculates the average of values. More...

#include <OMKConvertors.h>

Inheritance diagram for OMK::Iii::AverageT< Type >:

Inheritance graph
[legend]
Collaboration diagram for OMK::Iii::AverageT< Type >:

Collaboration graph
[legend]
List of all members.

Private Member Functions

 DECLARE_TEMPLATE_CONVERTOR_FACTORY (AverageT, Type, std::vector< Type >)

Detailed Description

template<typename Type>
class OMK::Iii::AverageT< Type >

Convertor class which calculates the average of values.

The class must be registered before using, so you have to use the following macro in your code (see REGISTER_TEMPLATE_CONVERTOR_FACTORY), replace #Type# by your type: float, double,...

#include "OMKConnectors.inl"
REGISTER_TEMPLATE_CONVERTOR_FACTORY( AverageT, #Type# , std::vector< #Type# >, Average#Type#  ) ;
In the main function of your code, call the registration
AverageT< #Type# , std::vector< #Type# > >::registerInFactory() ;
After that the user can define an average convertor in the configuration file for a connector:
...
Extensions
{
  interaction
  {
    Class Interactive
    Connectors
    {
      parameter_of_type_#Type#
      {
        Type Shared
        Convertor Average#Type# // <---Here
      }
    }
  }
}
...

Definition at line 72 of file OMKConvertors.h.


Member Function Documentation

template<typename Type>
OMK::Iii::AverageT< Type >::DECLARE_TEMPLATE_CONVERTOR_FACTORY ( AverageT< Type >  ,
Type  ,
std::vector< Type >   
) [private]


logo OpenMask

Documentation generated on Mon Jun 9 11:46:04 2008

Generated with doxygen by Dimitri van Heesch ,   1997-2007