GemaCoreLib
The GeMA Core library
Public Types | Public Member Functions | Public Attributes | Private Attributes | List of all members
GmCRVector Class Reference

An auxiliary vector WRAPPER that binds the vector to a CONST memory area with data already initialized. More...

#include <gmVector.h>

Public Types

typedef double elem_type
 the type of elements stored in the vector
 

Public Member Functions

 GmCRVector (const double *data, int nlin)
 Constructs the vector pointing to a const memory area.
 
 GmCRVector ()
 Constructs an empty vector that needs to be initialized later by a call to setMemory()
 
 operator const GmVector & ()
 Returns the wrapped vector as a CONST reference.
 
const GmVectorv ()
 Returns the wrapped vector as a CONST reference.
 
void setMemory (const double *data, int nlin)
 Exchanges the memory area used by the vector. Same caveats explained in the class documentation apply.
 
const double & operator[] (unsigned int ii) const
 
const double & at (unsigned int ii) const
 
const double & operator() (unsigned int ii) const
 
bool is_empty () const
 
bool in_range (unsigned int ii) const
 
const double * memptr () const
 
bool empty () const
 
unsigned int size () const
 

Public Attributes

const unsigned int n_rows
 number of rows in the vector (read-only)
 
const unsigned int n_cols
 number of columns in the vector (read-only)
 
const unsigned int n_elem
 number of elements in the vector (read-only)
 

Private Attributes

GmVector _vec
 The wrapped vector.
 

Detailed Description

An auxiliary vector WRAPPER that binds the vector to a CONST memory area with data already initialized.

See further IMPORTANT comments in GmCRMatrix documentation.


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