VIGRA - VIGRA: TinyVectorView Class Template Reference

[ VIGRA Homepage | Function Index | Class Index | Namespaces | File List | Main Page ]

| TinyVectorView |

Wrapper for fixed size vectors. More...

`#include <vigra/tinyvector.hxx>`

Inheritance diagram for TinyVectorView:

List of all members.

## Public Types
typedef BaseType::const_iterator | const_iterator
typedef BaseType::const_pointer | const_pointer
typedef BaseType::const_reference | const_reference
typedef BaseType::difference_type | difference_type
typedef BaseType::iterator | iterator
typedef BaseType::NormType | NormType
typedef BaseType::pointer | pointer
typedef BaseType::reference | reference
typedef BaseType::scalar_multiplier | scalar_multiplier
typedef BaseType::size_type | size_type
typedef BaseType::SquaredNormType | SquaredNormType
typedef BaseType::value_type | value_type
## Public Member Functions
template<class U, class DATA, class DERIVED>
TinyVectorView & | operator= (TinyVectorBase< U, SIZE, DATA, DERIVED > const &r)
TinyVectorView & | operator= (TinyVectorView const &r)
template<class DATA, class DERIVED>
| TinyVectorView (TinyVectorBase< T, SIZE, DATA, DERIVED > const &other)
| TinyVectorView (TinyVectorView const &other)
| TinyVectorView (const_pointer data)
| TinyVectorView ()

## Detailed Description

### template<class T, int SIZE>
class vigra::TinyVectorView< T, SIZE >

Wrapper for fixed size vectors.

This class wraps an array of size SIZE of the specified VALUETYPE. Thus, the array can be accessed with an interface similar to that of std::vector (except that there are no functions that change the size of a TinyVectorView). The TinyVectorView does not assume ownership of the given memory.

Arithmetic operations on TinyVectorViews are defined as component-wise applications of these operations. Addition and subtraction of two TinyVectorViews (+=, -=, +, -, unary -), multiplication and division of an TinyVectorViews with a double, and NumericTraits/PromoteTraits are defined, so that TinyVectorView fulfills the requirements of Linear Algebra.

VIGRA algorithms typically use vigra::VectorAccessor to access TinyVectorViews as a whole, or specific components of them.

See also:

- vigra::TinyVectorBase
- vigra::TinyVector
- Numeric and Promote Traits of TinyVector
- Functions for TinyVector

#include <vigra/tinyvector.hxx>
Namespace: vigra

## Member Typedef Documentation

typedef BaseType::const_iterator const_iterator

STL-compatible definition of const iterator

Reimplemented from TinyVectorBase.

typedef BaseType::const_pointer const_pointer

const pointer (return of operator-> const).

Reimplemented from TinyVectorBase.

typedef BaseType::const_reference const_reference

const reference (return of operator[] const).

Reimplemented from TinyVectorBase.

typedef BaseType::difference_type difference_type

STL-compatible definition of difference_type

Reimplemented from TinyVectorBase.

typedef BaseType::iterator iterator

STL-compatible definition of iterator

Reimplemented from TinyVectorBase.

typedef BaseType::NormType NormType

the vector's norm type

Reimplemented from TinyVectorBase.

typedef BaseType::pointer pointer

pointer (return of operator->).

Reimplemented from TinyVectorBase.

typedef BaseType::reference reference

reference (return of operator[]).

Reimplemented from TinyVectorBase.

typedef BaseType::scalar_multiplier scalar_multiplier

the scalar type for the outer product

Reimplemented from TinyVectorBase.

typedef BaseType::size_type size_type

STL-compatible definition of size_type

Reimplemented from TinyVectorBase.

typedef BaseType::SquaredNormType SquaredNormType

the vector's squared norm type

Reimplemented from TinyVectorBase.

typedef BaseType::value_type value_type

STL-compatible definition of valuetype

Reimplemented from TinyVectorBase.

## Constructor & Destructor Documentation

TinyVectorView | ( |  | ) |

Default constructor (pointer to wrapped data is NULL).

TinyVectorView | ( | const_pointer | data | ) |

Construct view for given data array

TinyVectorView | ( | TinyVectorView< T, SIZE > const & | other | ) |

Copy constructor (shallow copy).

template<class DATA, class DERIVED>
TinyVectorView | ( | TinyVectorBase< T, SIZE, DATA, DERIVED > const & | other | ) |

Construct view from other TinyVector.

## Member Function Documentation

TinyVectorView& operator= | ( | TinyVectorBase< U, SIZE, DATA, DERIVED > const & | r | ) |

Copy the data of the rhs with cast.

TinyVectorView& operator= | ( | TinyVectorView< T, SIZE > const & | r | ) |

Copy the data (not the pointer) of the rhs.

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

- vigra/tinyvector.hxx

© Ullrich Köthe (ullrich.koethe@iwr.uni-heidelberg.de) Heidelberg Collaboratory for Image Processing, University of Heidelberg, Germany | html generated using doxygen and Python VIGRA 1.6.0 (13 Aug 2008)