newspeoplefor developersdocumentationdownloads

nArray2< TYPE > Class Template Reference
[Data Types]

#include <narray2.h>

List of all members.


Detailed Description

template<class TYPE>
class nArray2< TYPE >

Fixed size two-dimensional array.

(C) 2004 RadonLabs GmbH

Definition at line 15 of file narray2.h.


Public Member Functions

 nArray2 ()
 default constructor
 nArray2 (uint width, uint height)
 constructor
 ~nArray2 ()
 destructor
nArray2< TYPE > & operator= (const nArray2< TYPE > &rhs)
 assignment operator
void SetSize (uint width, uint height)
 reset array's size
uint GetWidth () const
 get number of columns
uint GetHeight () const
 get number of rows
TYPE & At (uint x, uint y) const
 item at index (x, y).
void Set (uint x, uint y, const TYPE &elm)
 set value at (x, y)
bool ValidIndex (uint x, uint y) const
 is index <i, j> inside bounds?
void Clear (const TYPE &elm)
 clear with given value

Constructor & Destructor Documentation

template<class TYPE>
nArray2< TYPE >::nArray2  ) 
 

default constructor

Definition at line 58 of file narray2.h.

template<class TYPE>
nArray2< TYPE >::nArray2 uint  width,
uint  height
 

constructor

Definition at line 84 of file narray2.h.

template<class TYPE>
nArray2< TYPE >::~nArray2  ) 
 

destructor

Definition at line 126 of file narray2.h.


Member Function Documentation

template<class TYPE>
nArray2< TYPE > & nArray2< TYPE >::operator= const nArray2< TYPE > &  rhs  ) 
 

assignment operator

Definition at line 136 of file narray2.h.

template<class TYPE>
void nArray2< TYPE >::SetSize uint  width,
uint  height
 

reset array's size

Definition at line 148 of file narray2.h.

template<class TYPE>
uint nArray2< TYPE >::GetWidth  )  const
 

get number of columns

Definition at line 162 of file narray2.h.

template<class TYPE>
uint nArray2< TYPE >::GetHeight  )  const
 

get number of rows

Definition at line 172 of file narray2.h.

template<class TYPE>
TYPE & nArray2< TYPE >::At uint  x,
uint  y
const
 

item at index (x, y).

Definition at line 192 of file narray2.h.

template<class TYPE>
void nArray2< TYPE >::Set uint  x,
uint  y,
const TYPE &  elm
 

set value at (x, y)

Definition at line 204 of file narray2.h.

template<class TYPE>
bool nArray2< TYPE >::ValidIndex uint  x,
uint  y
const
 

is index <i, j> inside bounds?

Definition at line 182 of file narray2.h.

template<class TYPE>
void nArray2< TYPE >::Clear const TYPE &  elm  ) 
 

clear with given value

Definition at line 216 of file narray2.h.


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

Copyright © 1999-2005 by the contributing authors. Ideas, requests, problems: Send feedback.