Public Member Functions | Public Attributes | List of all members
RMLVector< T > Class Template Reference

This is a minimalistic dynamic vector class implementation used for the Reflexxes Motion Libraries. More...

#include <RMLVector.h>

Public Member Functions

T * GetReference (void) const
 Returns the data pointer of the vector object (not the pointer to the object) More...
 
unsigned int GetVecDim (void) const
 Returns the dimension of the vector. More...
 
bool operator!= (const RMLVector< T > &Vector) const
 Unequal operator. More...
 
RMLVectoroperator= (const RMLVector< T > &Vector)
 Copy operator. More...
 
bool operator== (const RMLVector< T > &Vector) const
 Equal operator. More...
 
T & operator[] (const int Index)
 Bracket operator, gives access to a single vector element. More...
 
const T & operator[] (const int Index) const
 Bracket operator, gives access to a single vector element. More...
 
 RMLVector (const RMLVector< T > &Vector)
 Copy constructor of class RMLVector. More...
 
 RMLVector (const unsigned int Size)
 Constructor of class RMLVector, allocates memory for a given number of double elements. More...
 
 RMLVector (const T &Component0, const T &Component1)
 Special 2D constructor. More...
 
 RMLVector (const T &Component0, const T &Component1, const T &Component2)
 Special 3D constructor. More...
 
 RMLVector (const T &Component0, const T &Component1, const T &Component2, const T &Component3)
 Special 4D constructor. More...
 
 RMLVector (const T &Component0, const T &Component1, const T &Component2, const T &Component3, const T &Component4)
 Special 5D constructor. More...
 
 RMLVector (const T &Component0, const T &Component1, const T &Component2, const T &Component3, const T &Component4, const T &Component5)
 Special 6D constructor. More...
 
 RMLVector (const T &Component0, const T &Component1, const T &Component2, const T &Component3, const T &Component4, const T &Component5, const T &Component6)
 Special 7D constructor. More...
 
void Set (const T Value)
 Sets all elements of a vector of double elements to one specific value. More...
 
 ~RMLVector (void)
 Destructor of class RMLVector. More...
 

Public Attributes

T * VecData
 Pointer to the actual vector data, that is, an array of type T objects. More...
 
unsigned int VectorDimension
 Contains the number of vector elements. More...
 

Detailed Description

template<class T = double>
class RMLVector< T >

This is a minimalistic dynamic vector class implementation used for the Reflexxes Motion Libraries.

Note
For all copy and comparison methods of this class, no check, whether two objects are of the same size, is implemented. In order to safe computation time, it is assumed that the used RMLVector objects are of the same size. Ensure that only RMLVector objects of equal size are used.
See also
RMLDoubleVector
RMLIntVector
RMLBoolVector

Definition at line 77 of file RMLVector.h.

Constructor & Destructor Documentation

template<class T = double>
RMLVector< T >::RMLVector ( const RMLVector< T > &  Vector)
inline

Copy constructor of class RMLVector.

Warning
This method is not real-time capable as heap memory has to be allocated.
Parameters
VectorOriginal object reference

Definition at line 94 of file RMLVector.h.

template<class T = double>
RMLVector< T >::RMLVector ( const unsigned int  Size)
inline

Constructor of class RMLVector, allocates memory for a given number of double elements.

Warning
This method is not real-time capable as heap memory has to be allocated.
Parameters
SizeDetermines the number of vector elements

Definition at line 116 of file RMLVector.h.

template<class T = double>
RMLVector< T >::RMLVector ( const T &  Component0,
const T &  Component1 
)
inline

Special 2D constructor.

Warning
This method is not real-time capable as heap memory has to be allocated.
Parameters
Component0Value of the first vector component
Component1Value of the second vector component

Definition at line 144 of file RMLVector.h.

template<class T = double>
RMLVector< T >::RMLVector ( const T &  Component0,
const T &  Component1,
const T &  Component2 
)
inline

Special 3D constructor.

Warning
This method is not real-time capable as heap memory has to be allocated.
Parameters
Component0Value of the first vector component
Component1Value of the second vector component
Component2Value of the third vector component

Definition at line 174 of file RMLVector.h.

template<class T = double>
RMLVector< T >::RMLVector ( const T &  Component0,
const T &  Component1,
const T &  Component2,
const T &  Component3 
)
inline

Special 4D constructor.

Warning
This method is not real-time capable as heap memory has to be allocated.
Parameters
Component0Value of the first vector component
Component1Value of the second vector component
Component2Value of the third vector component
Component3Value of the fourth vector component

Definition at line 209 of file RMLVector.h.

template<class T = double>
RMLVector< T >::RMLVector ( const T &  Component0,
const T &  Component1,
const T &  Component2,
const T &  Component3,
const T &  Component4 
)
inline

Special 5D constructor.

Warning
This method is not real-time capable as heap memory has to be allocated.
Parameters
Component0Value of the first vector component
Component1Value of the second vector component
Component2Value of the third vector component
Component3Value of the fourth vector component
Component4Value of the fifth vector component

Definition at line 248 of file RMLVector.h.

template<class T = double>
RMLVector< T >::RMLVector ( const T &  Component0,
const T &  Component1,
const T &  Component2,
const T &  Component3,
const T &  Component4,
const T &  Component5 
)
inline

Special 6D constructor.

Warning
This method is not real-time capable as heap memory has to be allocated.
Parameters
Component0Value of the first vector component
Component1Value of the second vector component
Component2Value of the third vector component
Component3Value of the fourth vector component
Component4Value of the fifth vector component
Component5Value of the sixth vector component

Definition at line 293 of file RMLVector.h.

template<class T = double>
RMLVector< T >::RMLVector ( const T &  Component0,
const T &  Component1,
const T &  Component2,
const T &  Component3,
const T &  Component4,
const T &  Component5,
const T &  Component6 
)
inline

Special 7D constructor.

Warning
This method is not real-time capable as heap memory has to be allocated.
Parameters
Component0Value of the first vector component
Component1Value of the second vector component
Component2Value of the third vector component
Component3Value of the fourth vector component
Component4Value of the fifth vector component
Component5Value of the sixth vector component
Component6Value of the seventh vector component

Definition at line 343 of file RMLVector.h.

template<class T = double>
RMLVector< T >::~RMLVector ( void  )
inline

Destructor of class RMLVector.

Definition at line 370 of file RMLVector.h.

Member Function Documentation

template<class T = double>
T * RMLVector< T >::GetReference ( void  ) const
inline

Returns the data pointer of the vector object (not the pointer to the object)

Returns
Data pointer

Definition at line 511 of file RMLVector.h.

template<class T = double>
unsigned int RMLVector< T >::GetVecDim ( void  ) const
inline

Returns the dimension of the vector.

Returns
Number of vector elements

Definition at line 497 of file RMLVector.h.

template<class T = double>
bool RMLVector< T >::operator!= ( const RMLVector< T > &  Vector) const
inline

Unequal operator.

Returns
true if all vector elements are equal and false in all other cases

Definition at line 482 of file RMLVector.h.

template<class T = double>
RMLVector & RMLVector< T >::operator= ( const RMLVector< T > &  Vector)
inline

Copy operator.

Parameters
VectorVector object to be copied

Definition at line 404 of file RMLVector.h.

template<class T = double>
bool RMLVector< T >::operator== ( const RMLVector< T > &  Vector) const
inline

Equal operator.

Returns
true if all vector elements are equal or false in all other cases

Definition at line 459 of file RMLVector.h.

template<class T = double>
T & RMLVector< T >::operator[] ( const int  Index)
inline

Bracket operator, gives access to a single vector element.

Parameters
IndexDetermines the desired vector element
Returns
Reference to one single vector element

Definition at line 426 of file RMLVector.h.

template<class T = double>
const T & RMLVector< T >::operator[] ( const int  Index) const
inline

Bracket operator, gives access to a single vector element.

Parameters
IndexDetermines the desired vector element
Returns
Constant pointer to one single vector element

Definition at line 444 of file RMLVector.h.

template<class T = double>
void RMLVector< T >::Set ( const T  Value)
inline

Sets all elements of a vector of double elements to one specific value.

Parameters
ValueValue for all elements of the vector

Definition at line 384 of file RMLVector.h.

Member Data Documentation

template<class T = double>
T * RMLVector< T >::VecData

Pointer to the actual vector data, that is, an array of type T objects.

Definition at line 524 of file RMLVector.h.

template<class T = double>
unsigned int RMLVector< T >::VectorDimension

Contains the number of vector elements.

Definition at line 533 of file RMLVector.h.


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


libreflexxestype2
Author(s):
autogenerated on Sat Nov 21 2020 03:17:35