Into

Modules

Documentation

classPiiUnaryMatrixTransform

#include <PiiConceptualMatrix.h>

A matrix that models the matrix concept by applying a unary function to another matrix.

Inherits PiiConceptualMatrix< PiiUnaryMatrixTransform< Matrix, UnaryFunction >, Matrix::implementationLevel >

Description

Given a model of the matrix concept, mat, and a function func, this matrix works as if it was the result of calculating func(mat). Note that PiiUnaryMatrixTransform is immutable. It provides no way of modifying the source data.

See also

Public types

typedef PiiMatrixTraits< PiiUnaryMatrixTransform< Matrix, UnaryFunction >, Matrix::implementationLevel >

Constructors and destructor

(
  • const Matrix & mat
  • const UnaryFunction & func
)

Public member functions

Traits::const_iterator
( )
Traits::const_column_iterator
(
  • int index
)
int
Traits::const_iterator
( )
Traits::value_type
(
  • int r
  • int c
)
Traits::const_row_iterator
(
  • int index
)
int
( )
template<class Matrix, class UnaryFunction>
PiiUnaryMatrixTransform< Matrix, UnaryFunction >
(
  • const Matrix & mat
  • const UnaryFunction & func
)

Creates a PiiUnaryMatrixTransform that returns func(mat).

Function details

Notes (0)

Add a note

Not a single note added yet. Be the first, add yours.