Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes

podarray< eT > Class Template Reference
[Podarray]

A lightweight array for POD types. If the amount of memory requested is small, the stack is used. More...

#include <podarray_proto.hpp>

List of all members.

Public Member Functions

 ~podarray ()
 podarray ()
 podarray (const podarray &x)
const podarrayoperator= (const podarray &x)
arma_inline podarray (const u32 new_N)
arma_inline podarray (const eT *X, const u32 new_N)
arma_inline eT & operator[] (const u32 i)
arma_inline eT operator[] (const u32 i) const
arma_inline eT & operator() (const u32 i)
arma_inline eT operator() (const u32 i) const
void set_size (const u32 new_n_elem)
void fill (const eT val)
void zeros ()
void zeros (const u32 new_n_elem)
arma_inline eT * memptr ()
arma_inline const eT * memptr () const

Public Attributes

arma_aligned const u32 n_elem
 number of elements held
arma_aligned const eT *const mem
 pointer to memory used by the object

Protected Member Functions

void init (const u32 new_n_elem)

Protected Attributes

arma_aligned eT mem_local [16]
 Internal memory, to avoid calling the 'new' operator for small amounts of memory.

Detailed Description

template<typename eT>
class podarray< eT >

A lightweight array for POD types. If the amount of memory requested is small, the stack is used.

Definition at line 25 of file podarray_proto.hpp.


Member Data Documentation

template<typename eT>
arma_aligned const u32 podarray< eT >::n_elem
template<typename eT>
arma_aligned const eT* const podarray< eT >::mem
template<typename eT>
arma_aligned eT podarray< eT >::mem_local[16] [protected]

Internal memory, to avoid calling the 'new' operator for small amounts of memory.

Definition at line 35 of file podarray_proto.hpp.

Referenced by podarray< eT >::init(), and podarray< eT >::~podarray().