#include <json_batchallocator.h>
Classes | |
struct | BatchInfo |
Public Types | |
typedef AllocatedType | Type |
Public Member Functions | |
AllocatedType * | allocate () |
BatchAllocator (unsigned int objectsPerPage=255) | |
void | release (AllocatedType *object) |
~BatchAllocator () | |
Private Member Functions | |
BatchAllocator (const BatchAllocator &) | |
void | operator= (const BatchAllocator &) |
Static Private Member Functions | |
static BatchInfo * | allocateBatch (unsigned int objectsPerPage) |
Private Attributes | |
BatchInfo * | batches_ |
BatchInfo * | currentBatch_ |
AllocatedType * | freeHead_ |
Head of a single linked list within the allocated space of freeed object. More... | |
unsigned int | objectsPerPage_ |
Definition at line 25 of file json_batchallocator.h.
typedef AllocatedType Json::BatchAllocator< AllocatedType, objectPerAllocation >::Type |
Definition at line 28 of file json_batchallocator.h.
|
inline |
Definition at line 30 of file json_batchallocator.h.
References Json::BatchAllocator< AllocatedType, objectPerAllocation >::allocateBatch(), assert(), Json::BatchAllocator< AllocatedType, objectPerAllocation >::batches_, and Json::BatchAllocator< AllocatedType, objectPerAllocation >::currentBatch_.
|
inline |
Definition at line 41 of file json_batchallocator.h.
References python.rootplot.core::batch, and Json::BatchAllocator< AllocatedType, objectPerAllocation >::batches_.
|
private |
|
inline |
allocate space for an array of objectPerAllocation object.
Definition at line 53 of file json_batchallocator.h.
References Json::BatchAllocator< AllocatedType, objectPerAllocation >::allocateBatch(), Json::BatchAllocator< AllocatedType, objectPerAllocation >::batches_, Json::BatchAllocator< AllocatedType, objectPerAllocation >::currentBatch_, Json::BatchAllocator< AllocatedType, objectPerAllocation >::BatchInfo::end_, Json::BatchAllocator< AllocatedType, objectPerAllocation >::freeHead_, Json::BatchAllocator< AllocatedType, objectPerAllocation >::BatchInfo::next_, Json::BatchAllocator< AllocatedType, objectPerAllocation >::objectsPerPage_, and Json::BatchAllocator< AllocatedType, objectPerAllocation >::BatchInfo::used_.
|
inlinestaticprivate |
Definition at line 101 of file json_batchallocator.h.
References python.rootplot.core::batch, Json::BatchAllocator< AllocatedType, objectPerAllocation >::BatchInfo::next_, and Json::BatchAllocator< AllocatedType, objectPerAllocation >::BatchInfo::used_.
Referenced by Json::BatchAllocator< AllocatedType, objectPerAllocation >::allocate(), and Json::BatchAllocator< AllocatedType, objectPerAllocation >::BatchAllocator().
|
private |
|
inline |
Release the object.
Definition at line 81 of file json_batchallocator.h.
References assert(), and Json::BatchAllocator< AllocatedType, objectPerAllocation >::freeHead_.
Referenced by cuy.ValElement::__init__().
|
private |
Definition at line 112 of file json_batchallocator.h.
Referenced by Json::BatchAllocator< AllocatedType, objectPerAllocation >::allocate(), Json::BatchAllocator< AllocatedType, objectPerAllocation >::BatchAllocator(), and Json::BatchAllocator< AllocatedType, objectPerAllocation >::~BatchAllocator().
|
private |
Definition at line 113 of file json_batchallocator.h.
Referenced by Json::BatchAllocator< AllocatedType, objectPerAllocation >::allocate(), and Json::BatchAllocator< AllocatedType, objectPerAllocation >::BatchAllocator().
|
private |
Head of a single linked list within the allocated space of freeed object.
Definition at line 115 of file json_batchallocator.h.
Referenced by Json::BatchAllocator< AllocatedType, objectPerAllocation >::allocate(), and Json::BatchAllocator< AllocatedType, objectPerAllocation >::release().
|
private |
Definition at line 116 of file json_batchallocator.h.
Referenced by Json::BatchAllocator< AllocatedType, objectPerAllocation >::allocate().