cisst-saw
|
Define store back unary operations on an object as classes. More...
#include <vctStoreBackUnaryOperations.h>
Classes | |
class | MakeAbs |
Returns the absolute value of the input as an OutputType object. More... | |
class | MakeCeil |
Returns the ceiling of the input, that is, the smallest integer greater-than or equal to the input, as an OutputType object. More... | |
class | MakeFloor |
Returns the floor of the input, that is, the largest integer less-than or equal to the input, as an OutputType object. More... | |
class | MakeNegation |
Returns the negation of the input as an OutputType object. More... | |
Public Types | |
typedef _inputOutputElementType | InputOutputElementType |
Define store back unary operations on an object as classes.
Class vctStoreBackUnaryOperations is an envelope that wraps unary store back operations on an object as classes. vctStoreBackUnaryOperations defines internal classes such as MakeAbs, MakeNegation, 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 InputOutputType Operate(const InputOutputType & inputOutput)
Where InputOutputType is the type 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 .
inputOutputElementType | the type of the operand |
typedef _inputOutputElementType vctStoreBackUnaryOperations< _inputOutputElementType >::InputOutputElementType |