ERC CISST - cisst software

vctUnaryOperations< _outputElementType, _inputElementType > Class Template Reference

#include <vctUnaryOperations.h>

List of all members.


Detailed Description

template<class _outputElementType, class _inputElementType = _outputElementType>
class vctUnaryOperations< _outputElementType, _inputElementType >

Define unary operations on an object as classes.

Class vctUnaryOperations is an envelope that wraps unary operations on an object as classes. vctUnaryOperations defines internal classes such as Identity, AbsValue, etc., and each of the internal classes has one static function named Operate(), which wraps the corresponding operation. The signature of a typical Operate() is

 static inline OutputType Operate(const InputType & input)
  

Where OutputType, InputType, are the types of the result and the operand.

By abstracting very simple operations as inline functions, we can plug the vctUnaryOperations internal classes into templated vector operation engines. See an example of such engine in vctFixedSizeVectorRecursiveEngines.h , and an example of plugging an operation into the engine in vctFixedSizeVectorOperations.h .

Parameters:
inputElementType the type of the first (left-side) operand
outputElementType the type of the result
See also:
Identity AbsValue Square Negation

Definition at line 58 of file vctUnaryOperations.h.

Public Types

Classes


The documentation for this class was generated from the following file:
erc-cisst-devel<at>lists.johnshopkins.edu