PERRY v1.0.0
P-E-R-R-Y/PERRY helps creating games with a bunch of tools.
Loading...
Searching...
No Matches
Matrice< T > Class Template Reference

Public Member Functions

 Matrice (int rows, int cols)
 Construct a new Matrice object.
 
 Matrice (const std::vector< std::vector< T > > &grid)
 Construct a new Matrice object.
 
T & operator() (int row, int col)
 get the value of the matrix at the given row and column
 
const T & operator() (int row, int col) const
 get the unmutable value of the matrix at the given row and column
 
Matrice< T > operator= (const Matrice< T > &other)
 copy constructor
 
int getRows () const
 Get the Rows object.
 
int getCols () const
 Get the Cols object.
 
void print () const
 Print the matrix.
 

Private Attributes

std::vector< std::vector< T > > data
 
int rows
 
int cols
 

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