Yet Another Game Engine
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | List of all members
yage::Vector< Rows, Type > Class Template Reference

#include <matrix.h>

Inheritance diagram for yage::Vector< Rows, Type >:
yage::Matrix< Rows, 1, Type >

Public Member Functions

 Vector ()
 
 Vector (const Matrix< Rows, 1, Type > &other)
 
 Vector (const std::vector< Type > &data)
 
Type & operator[] (int col)
 
const Type & operator[] (int col) const
 
std::string toString () const override
 Prints out the matrix, but can also be implemented by other classes to print data differently. More...
 
- Public Member Functions inherited from yage::Matrix< Rows, 1, Type >
 Matrix ()
 Initializes the size of the data_ vector. More...
 
 Matrix (const std::vector< Type > &data)
 
int rowSize () const
 Returns the row size of the Matrix. More...
 
int colSize () const
 Returns the column size of the Matrix. More...
 
Matrix< 1, Cols, Type > getRow (int row) const
 Return the row specified row as a Matrix with only one row. More...
 
Matrix< Rows, 1, Type > getCol (int col) const
 Get a specific column in a column vector. More...
 
std::vector< Type >::iterator begin ()
 Iterator support for the start. More...
 
std::vector< Type >::iterator end ()
 Iterator support for the end. More...
 
details::Row< Rows, Cols, Type > operator[] (int row)
 
details::Row< Rows, Cols, Type > operator[] (int row) const
 
Matrix< Rows, Cols, Type > & operator+= (const Matrix< Rows, Cols, Type > &rhs)
 
Matrix< Rows, Cols, Type > & operator-= (const Matrix< Rows, Cols, Type > &rhs)
 

Additional Inherited Members

- Protected Attributes inherited from yage::Matrix< Rows, 1, Type >
std::vector< Type > data_
 Vector containing the data of the matrix. More...
 

Constructor & Destructor Documentation

template<int Rows = 2, class Type = double>
yage::Vector< Rows, Type >::Vector ( )
inline
template<int Rows = 2, class Type = double>
yage::Vector< Rows, Type >::Vector ( const Matrix< Rows, 1, Type > &  other)
inline
template<int Rows = 2, class Type = double>
yage::Vector< Rows, Type >::Vector ( const std::vector< Type > &  data)
inline

Member Function Documentation

template<int Rows = 2, class Type = double>
Type& yage::Vector< Rows, Type >::operator[] ( int  col)
inline
template<int Rows = 2, class Type = double>
const Type& yage::Vector< Rows, Type >::operator[] ( int  col) const
inline
template<int Rows = 2, class Type = double>
std::string yage::Vector< Rows, Type >::toString ( ) const
inlineoverridevirtual

Prints out the matrix, but can also be implemented by other classes to print data differently.

Bug:
When printing certain matrices, it omits a row or column. Still need to determine under which conditions.

Reimplemented from yage::Matrix< Rows, 1, Type >.


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