Inherits ltl::FVMemory< T, N, S >< T, N, S >.
FVector
rhs. empty()
. Always false. Can either have its own memory region or reference foreign memory, for example when representing a column-vector of a matrix
The template parameter S is a 'stride' for the foreign memory: when we reference a column vector we need a stride of M (if the matrix is MxN). Memory handling is encapsulated in the class FVMemory. To make life easier for the compiler/optimizer, there is a specialization of FVMemory with _no_ stride at all and an own new embedded block of memory. This is indicated by S=0, which is also the default case.
FVector
provides operator() for 1-based access and operator[] for 0-based access. A full expression-templated engine for evaluating expressions involving ltl::FVectors is provided, as well as dot products between ltl::FVector and ltl::FMatrix objects, and scalar-valued reductions.
STL-compatible iterators and types.
typedef T ltl::FVector< T, N, S >::value_type |
STL-compatible type definitions.
typedef FVIter<T,N,S> ltl::FVector< T, N, S >::iterator |
typedef FVIterConst<T,N,S> ltl::FVector< T, N, S >::const_iterator |
typedef T* ltl::FVector< T, N, S >::pointer |
typedef const T* ltl::FVector< T, N, S >::const_pointer |
typedef T& ltl::FVector< T, N, S >::reference |
typedef const T& ltl::FVector< T, N, S >::const_reference |
typedef std::size_t ltl::FVector< T, N, S >::size_type |
typedef std::ptrdiff_t ltl::FVector< T, N, S >::difference_type |
anonymous enum |
ltl::FVector< T, N, S >::FVector | ( | ) | [inline] |
default constructor
ltl::FVector< T, N, S >::~FVector | ( | ) | [inline] |
destructor
ltl::FVector< T, N, S >::FVector | ( | const FVector< T, N, S > & | other | ) |
copy constructor
ltl::FVector< T, N, S >::FVector | ( | T *const | a | ) |
constructor taking a pointer to foreign memory. If S==0
, copy, else reference the foreign memory.
ltl::FVector< T, N, S >::FVector | ( | const T | t | ) |
fill with value t
.
ltl::FVector< T, N, S >::FVector | ( | const FVExprNode< Expr, N > & | e | ) | [inline] |
construct from expression
static size_type ltl::FVector< T, N, S >::size | ( | ) | [inline, static] |
STL return the length of the vector.
Functions needed for STL container conformance
static bool ltl::FVector< T, N, S >::empty | ( | ) | [inline, static] |
STL empty()
. Always false.
static size_type ltl::FVector< T, N, S >::max_size | ( | ) | [inline, static] |
STL: Maximum capacity. Always ==size
().
ListInitializationSwitch< FVector<T,N,S> > ltl::FVector< T, N, S >::operator= | ( | T | x | ) | [inline] |
Initialize with list of values or single value.
Assign values through initialization list. A bit more comlicated since we have to discriminate between A = 3; and A = 1, 2, 3, 4; which is done using ListInitializationSwitch which either calls ListInitializer
or FVector::fill()
.
static int ltl::FVector< T, N, S >::length | ( | ) | [inline, static] |
return length of vector.
operator[] and operator() inherited from FVMemory
static int ltl::FVector< T, N, S >::minIndex | ( | ) | [inline, static] |
lowest possible index, always one.
static int ltl::FVector< T, N, S >::maxIndex | ( | ) | [inline, static] |
highest possible index, always N.
iterator ltl::FVector< T, N, S >::begin | ( | ) | [inline] |
return an iterator pointing to the first element.
const_iterator ltl::FVector< T, N, S >::begin | ( | ) | const [inline] |
return a const iterator pointing to the first element.
iterator ltl::FVector< T, N, S >::end | ( | ) | [inline] |
return an iterator pointing past the last element.
const_iterator ltl::FVector< T, N, S >::end | ( | ) | const [inline] |
return a const iterator pointing past the last element.
void ltl::FVector< T, N, S >::fill | ( | const T | x | ) |
fill with value x
.
FVector<T,N,S>& ltl::FVector< T, N, S >::operator= | ( | const FVExprNode< Expr, N > & | e | ) | [inline] |
operatorX=
for expression rhs.
FVector<T,N,S>& ltl::FVector< T, N, S >::operator+= | ( | const FVExprNode< Expr, N > & | e | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator-= | ( | const FVExprNode< Expr, N > & | e | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator *= | ( | const FVExprNode< Expr, N > & | e | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator/= | ( | const FVExprNode< Expr, N > & | e | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator%= | ( | const FVExprNode< Expr, N > & | e | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator^= | ( | const FVExprNode< Expr, N > & | e | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator &= | ( | const FVExprNode< Expr, N > & | e | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator|= | ( | const FVExprNode< Expr, N > & | e | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator<<= | ( | const FVExprNode< Expr, N > & | e | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator>>= | ( | const FVExprNode< Expr, N > & | e | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator= | ( | const FVector< T2, N, S2 > & | v | ) | [inline] |
operatorX for FVector
rhs.
FVector<T,N,S>& ltl::FVector< T, N, S >::operator= | ( | const FVector< T, N, S > & | v | ) |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator+= | ( | const FVector< T2, N, S2 > & | v | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator-= | ( | const FVector< T2, N, S2 > & | v | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator *= | ( | const FVector< T2, N, S2 > & | v | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator/= | ( | const FVector< T2, N, S2 > & | v | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator%= | ( | const FVector< T2, N, S2 > & | v | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator^= | ( | const FVector< T2, N, S2 > & | v | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator &= | ( | const FVector< T2, N, S2 > & | v | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator|= | ( | const FVector< T2, N, S2 > & | v | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator<<= | ( | const FVector< T2, N, S2 > & | v | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator>>= | ( | const FVector< T2, N, S2 > & | v | ) | [inline] |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator+= | ( | const T | t | ) |
operatorX= for scalar rhs.
FVector<T,N,S>& ltl::FVector< T, N, S >::operator-= | ( | const T | t | ) |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator *= | ( | const T | t | ) |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator/= | ( | const T | t | ) |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator%= | ( | const T | t | ) |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator^= | ( | const T | t | ) |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator &= | ( | const T | t | ) |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator|= | ( | const T | t | ) |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator<<= | ( | const T | t | ) |
FVector<T,N,S>& ltl::FVector< T, N, S >::operator>>= | ( | const T | t | ) |
void ltl::FVector< T, N, S >::swap | ( | FVector< T2, N, S2 > & | other | ) | [inline] |
swap values with other
.
T ltl::FVMemory< T, N, S >::operator[] | ( | const int | i | ) | const [inline, inherited] |
Access elements with zero-based index i
.
T& ltl::FVMemory< T, N, S >::operator[] | ( | const int | i | ) | [inline, inherited] |
Access elements with zero-based index i
.
T ltl::FVMemory< T, N, S >::operator() | ( | const int | i | ) | const [inline, inherited] |
Access elements with one-based index i
.
T& ltl::FVMemory< T, N, S >::operator() | ( | const int | i | ) | [inline, inherited] |
Access elements with one-based index i
.
T* ltl::FVMemory< T, N, S >::data | ( | ) | [inline, inherited] |
Return a pointer to the data.
T* ltl::FVMemory< T, N, S >::data | ( | ) | const [inline, inherited] |
Return a const pointer to the data.
friend class FVIter< T, N, S > [friend] |
friend class FVIterConst< T, N, S > [friend] |
friend class ListInitializationSwitch< FVector< T, N, S > > [friend] |
ostream & operator<< | ( | ostream & | os, | |
const FVector< T, N, S > & | x | |||
) | [related] |
Write ltl::FVector to ascii stream. Compatible with opertor>>
.
istream & operator>> | ( | istream & | is, | |
FVector< T, N, S > & | x | |||
) | [related] |
Read ltl::FVector from ascii stream. Compatible with operator<<
.
T* ltl::FVMemory< T, N, S >::__data_ [protected, inherited] |
points to first element of data block for 0-based access
T* ltl::FVMemory< T, N, S >::data_ [protected, inherited] |
points to __data-S
for 1-based access