Ne.app NeANT
The Ne.app NeANT User module of the NeANT distribution.
Public Types | Public Member Functions | Static Public Member Functions | Data Fields
SharedAlloc Struct Reference

#include <rw_allocator.h>

Public Types

enum  MemFun {
  m_ctor , m_cpy_ctor , m_cvt_ctor , m_cpy_assign ,
  m_cvt_assign , m_dtor , m_allocate , m_deallocate ,
  m_construct , m_destroy , m_address , m_max_size ,
  n_funs
}
 

Public Member Functions

 SharedAlloc (_RWSTD_SIZE_T=_RWSTD_SIZE_MAX, _RWSTD_SIZE_T=_RWSTD_SIZE_MAX)
 
virtual ~SharedAlloc ()
 
virtual void * allocate (_RWSTD_SIZE_T, _RWSTD_SIZE_T, const void *)
 
virtual void deallocate (void *, _RWSTD_SIZE_T, _RWSTD_SIZE_T)
 
virtual _RWSTD_SIZE_T max_size (_RWSTD_SIZE_T=1)
 
virtual void funcall (MemFun, const SharedAlloc *=0)
 
int id () const
 
void reset_call_counters ()
 

Static Public Member Functions

static SharedAlloc * instance (SharedAlloc *=0)
 
static const char * func_name (MemFun)
 

Data Fields

_RWSTD_SIZE_T max_bytes_
 
_RWSTD_SIZE_T max_blocks_
 
_RWSTD_SIZE_T n_bytes_
 
_RWSTD_SIZE_T n_blocks_
 
_RWSTD_SIZE_T n_refs_
 
_RWSTD_SIZE_T n_calls_ [n_funs]
 
_RWSTD_SIZE_T n_throws_ [n_funs]
 
_RWSTD_SIZE_T throw_at_calls_ [n_funs]
 

Detailed Description

Definition at line 46 of file rw_allocator.h.

Member Enumeration Documentation

◆ MemFun

Enumerator
m_ctor 
m_cpy_ctor 
m_cvt_ctor 
m_cpy_assign 
m_cvt_assign 
m_dtor 
m_allocate 
m_deallocate 
m_construct 
m_destroy 
m_address 
m_max_size 
n_funs 

Definition at line 49 of file rw_allocator.h.

Constructor & Destructor Documentation

◆ SharedAlloc()

SharedAlloc::SharedAlloc ( _RWSTD_SIZE_T  = _RWSTD_SIZE_MAX,
_RWSTD_SIZE_T  = _RWSTD_SIZE_MAX 
)

Definition at line 62 of file allocator.cpp.

◆ ~SharedAlloc()

SharedAlloc::~SharedAlloc ( )
virtual

Definition at line 73 of file allocator.cpp.

Member Function Documentation

◆ allocate()

void * SharedAlloc::allocate ( _RWSTD_SIZE_T  ,
_RWSTD_SIZE_T  ,
const void *   
)
virtual

Definition at line 102 of file allocator.cpp.

◆ deallocate()

void SharedAlloc::deallocate ( void *  ,
_RWSTD_SIZE_T  ,
_RWSTD_SIZE_T   
)
virtual

Definition at line 123 of file allocator.cpp.

◆ func_name()

const char * SharedAlloc::func_name ( MemFun  mf)
static

Definition at line 249 of file allocator.cpp.

◆ funcall()

void SharedAlloc::funcall ( MemFun  mf,
const SharedAlloc *  other = 0 
)
virtual

Definition at line 141 of file allocator.cpp.

◆ id()

int SharedAlloc::id ( ) const
inline

Definition at line 101 of file rw_allocator.h.

◆ instance()

SharedAlloc * SharedAlloc::instance ( SharedAlloc *  pinst = 0)
static

Definition at line 212 of file allocator.cpp.

◆ max_size()

size_t SharedAlloc::max_size ( _RWSTD_SIZE_T  = 1)
virtual

Definition at line 132 of file allocator.cpp.

◆ reset_call_counters()

void SharedAlloc::reset_call_counters ( )

Definition at line 242 of file allocator.cpp.

Field Documentation

◆ max_blocks_

_RWSTD_SIZE_T SharedAlloc::max_blocks_

Definition at line 110 of file rw_allocator.h.

◆ max_bytes_

_RWSTD_SIZE_T SharedAlloc::max_bytes_

Definition at line 109 of file rw_allocator.h.

◆ n_blocks_

_RWSTD_SIZE_T SharedAlloc::n_blocks_

Definition at line 113 of file rw_allocator.h.

◆ n_bytes_

_RWSTD_SIZE_T SharedAlloc::n_bytes_

Definition at line 112 of file rw_allocator.h.

◆ n_calls_

_RWSTD_SIZE_T SharedAlloc::n_calls_[n_funs]

Definition at line 119 of file rw_allocator.h.

◆ n_refs_

_RWSTD_SIZE_T SharedAlloc::n_refs_

Definition at line 115 of file rw_allocator.h.

◆ n_throws_

_RWSTD_SIZE_T SharedAlloc::n_throws_[n_funs]

Definition at line 123 of file rw_allocator.h.

◆ throw_at_calls_

_RWSTD_SIZE_T SharedAlloc::throw_at_calls_[n_funs]

Definition at line 127 of file rw_allocator.h.


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