OpenFPM_data  0.1.0
Project that contain the implementation and interfaces for basic structure like vectors, grids, graph ... .
 All Data Structures Namespaces Functions Variables Typedefs Friends
memory_array< T > Class Template Reference

This class give a representation to a chunk or memory. More...

Detailed Description

template<typename T>
class memory_array< T >

This class give a representation to a chunk or memory.

This class give a representation to a chunk of memory as an array of T objects

Parameters
TThis is the object type

Definition at line 25 of file memory_array.hpp.

#include <memory_array.hpp>

Public Member Functions

void set_pointer (void *ptr_)
 Set the internal pointer to the indicated chunk of memory.
 
void * get_pointer ()
 Return the pointer.
 
T & operator[] (mem_id i)
 operator[]
 
 memory_array ()
 Default constructor.
 
 memory_array (void *ptr, size_t sz, bool init)
 Memory array constructor. More...
 

Private Member Functions

get (mem_id i)
 return the i element
 

Private Attributes

T * ptr
 Internal pointer.
 

Constructor & Destructor Documentation

template<typename T >
memory_array< T >::memory_array ( void *  ptr,
size_t  sz,
bool  init 
)
inline

Memory array constructor.

Parameters
ptrMemory pointer
szsize
initspecify if the pointer is initialized

Definition at line 66 of file memory_array.hpp.


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