Public Member Functions | Protected Attributes | List of all members
SimpleIntArray Class Reference

#include <newmat.h>

Inheritance diagram for SimpleIntArray:
Inheritance graph
[legend]

Public Member Functions

void cleanup ()
 set length to zero More...
 
void CleanUp ()
 set length to zero More...
 
const int * const_data () const
 pointer to the data More...
 
int * Data ()
 pointer to the data More...
 
const int * Data () const
 pointer to the data More...
 
int * data ()
 pointer to the data More...
 
const int * data () const
 pointer to the data More...
 
void ReSize (int i, bool keep=false)
 change length, keep data if keep = true More...
 
void resize_keep (int i)
 change length, keep data More...
 
 SimpleIntArray ()
 build an array length 0 More...
 
int Size () const
 return the size of the array More...
 
int size () const
 return the size of the array More...
 
 SimpleIntArray (int xn)
 build an array length xn More...
 
 ~SimpleIntArray ()
 return the space to memory More...
 
int & operator[] (int i)
 access element of the array - start at 0 More...
 
int operator[] (int i) const
 access element of constant array More...
 
void operator= (int ai)
 set the array equal to a constant More...
 
void operator= (const SimpleIntArray &b)
 copy the elements of an array More...
 
 SimpleIntArray (const SimpleIntArray &b)
 make a new array equal to an existing one More...
 
void resize (int i, bool keep=false)
 change length, keep data if keep = true More...
 
- Public Member Functions inherited from Janitor
 Janitor ()
 
virtual ~Janitor ()
 

Protected Attributes

int * a
 pointer to the array More...
 
int n
 length of the array More...
 

Detailed Description

A very simple integer array class. A minimal array class to imitate a C style array but giving dynamic storage mostly intended for internal use by newmat. Probably to be replaced by a templated class when I start using templates.

Definition at line 1852 of file newmat.h.

Constructor & Destructor Documentation

SimpleIntArray::SimpleIntArray ( int  xn)

build an array length xn

Definition at line 1163 of file newmat4.cpp.

SimpleIntArray::SimpleIntArray ( )
inline

build an array length 0

Definition at line 1859 of file newmat.h.

SimpleIntArray::~SimpleIntArray ( )

return the space to memory

Definition at line 1172 of file newmat4.cpp.

SimpleIntArray::SimpleIntArray ( const SimpleIntArray b)

make a new array equal to an existing one

Definition at line 1214 of file newmat4.cpp.

Member Function Documentation

void SimpleIntArray::cleanup ( )
inline

set length to zero

Definition at line 1884 of file newmat.h.

void SimpleIntArray::CleanUp ( )
inlinevirtual

set length to zero

Reimplemented from Janitor.

Definition at line 1885 of file newmat.h.

const int* SimpleIntArray::const_data ( ) const
inline

pointer to the data

Definition at line 1877 of file newmat.h.

int* SimpleIntArray::Data ( )
inline

pointer to the data

Definition at line 1873 of file newmat.h.

const int* SimpleIntArray::Data ( ) const
inline

pointer to the data

Definition at line 1874 of file newmat.h.

int* SimpleIntArray::data ( )
inline

pointer to the data

Definition at line 1875 of file newmat.h.

const int* SimpleIntArray::data ( ) const
inline

pointer to the data

Definition at line 1876 of file newmat.h.

void SimpleIntArray::operator= ( int  ai)

set the array equal to a constant

Definition at line 1198 of file newmat4.cpp.

void SimpleIntArray::operator= ( const SimpleIntArray b)

copy the elements of an array

Definition at line 1204 of file newmat4.cpp.

int & SimpleIntArray::operator[] ( int  i)

access element of the array - start at 0

Definition at line 1179 of file newmat4.cpp.

int SimpleIntArray::operator[] ( int  i) const

access element of constant array

Definition at line 1189 of file newmat4.cpp.

void SimpleIntArray::resize ( int  i,
bool  keep = false 
)

change length, keep data if keep = true

Definition at line 1228 of file newmat4.cpp.

void SimpleIntArray::ReSize ( int  i,
bool  keep = false 
)
inline

change length, keep data if keep = true

Definition at line 1880 of file newmat.h.

void SimpleIntArray::resize_keep ( int  i)
inline

change length, keep data

Definition at line 1882 of file newmat.h.

int SimpleIntArray::Size ( ) const
inline

return the size of the array

Definition at line 1869 of file newmat.h.

int SimpleIntArray::size ( ) const
inline

return the size of the array

Definition at line 1871 of file newmat.h.

Member Data Documentation

int* SimpleIntArray::a
protected

pointer to the array

Definition at line 1855 of file newmat.h.

int SimpleIntArray::n
protected

length of the array

Definition at line 1856 of file newmat.h.


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


kni
Author(s): Martin Günther
autogenerated on Fri Jan 3 2020 04:01:17