Particle Identification and Tracking
Public Member Functions | Protected Attributes
utilities::Array Class Reference

Class to accumulate tuples into. More...

#include <array.h>

+ Collaboration diagram for utilities::Array:

List of all members.

Public Member Functions

 Array (int rows)
 Constructor.
void clear ()
 Clears the array.
void clear (int rows)
 Clears and resizes the array.
int get_col_num () const
 Returns the number of columns.
int get_row_num () const
 Returns the number of rows.
void print ()
 Sensible printing.
void push (const Tuplef &tuple_in)
 Adds a tuple to the end of the array.
void resize (int rows)
 resizes the array
void set_array (Generic_wrapper_base *out_wrapper) const
 Outputs the whole array to the specified output wrapper.

Protected Attributes

int cols_
 number of colmuns
int cur_index_
 The current row, in [0,rows_-1].
std::vector< double > data_
 Vector to hold data.
int rows_
 Number of rows.

Detailed Description

Class to accumulate tuples into.

Each tuple added is a row. The number of columns is set by the size of Tuplei and Tuplef. This has some very bad naming conventions and is primarily used in the matlab related code. This class should probably go away.


Constructor & Destructor Documentation

Array::Array ( int  rows)

Constructor.

References rows_.


Member Function Documentation

void Array::clear ( )
void Array::clear ( int  rows)

Clears and resizes the array.

References cols_, cur_index_, data_, and rows_.

int utilities::Array::get_col_num ( ) const [inline]

Returns the number of columns.

References cols_.

Referenced by utilities::Cell_matlab::add_array().

int utilities::Array::get_row_num ( ) const [inline]

Returns the number of rows.

References rows_.

Referenced by utilities::Cell_matlab::add_array().

void Array::print ( )

Sensible printing.

References cols_, data_, and rows_.

void Array::push ( const Tuplef &  tuple_in)

Adds a tuple to the end of the array.

References cols_, cur_index_, data_, and rows_.

Referenced by tracking::Track_box::extract_corrected_disp(), and tracking::Track_box::extract_raw_disp().

void Array::resize ( int  rows)

resizes the array

References cols_, data_, and rows_.

void Array::set_array ( Generic_wrapper_base out_wrapper) const

Member Data Documentation

int utilities::Array::cols_ [protected]

number of colmuns

Referenced by clear(), get_col_num(), print(), push(), resize(), and set_array().

The current row, in [0,rows_-1].

Referenced by clear(), and push().

std::vector<double> utilities::Array::data_ [protected]

Vector to hold data.

Referenced by clear(), print(), push(), resize(), and set_array().

int utilities::Array::rows_ [protected]

Number of rows.

Referenced by Array(), clear(), get_row_num(), print(), push(), resize(), and set_array().


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