cocos2d-x  3.4
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
AllocatorStrategyPool< T, O, locking_traits > Class Template Reference

#include <CCAllocatorStrategyPool.h>

Inheritance diagram for AllocatorStrategyPool< T, O, locking_traits >:
AllocatorStrategyFixedBlock< sizeof(T), O::alignment, locking_traits > AllocatorBase

Public Types

typedef T value_type
typedef value_typepointer
typedef
AllocatorStrategyFixedBlock
< sizeof(T), O::alignment,
locking_traits > 
tParentStrategy
- Public Types inherited from AllocatorBase
enum  { kDefaultAlignment = 16 }
 
typedef void * pointer

Public Member Functions

 AllocatorStrategyPool (const char *tag=nullptr, size_t poolSize=100)
CC_ALLOCATOR_INLINE void * allocate (size_t size)
CC_ALLOCATOR_INLINE void deallocate (void *address, size_t size=0)
- Public Member Functions inherited from AllocatorStrategyFixedBlock< sizeof(T), O::alignment, locking_traits >
 AllocatorStrategyFixedBlock (const char *tag=nullptr, size_t pageSize=100)
virtual ~AllocatorStrategyFixedBlock ()
CC_ALLOCATOR_INLINE void * allocate (size_t size)
CC_ALLOCATOR_INLINE void deallocate (void *address, size_t size=0)
CC_ALLOCATOR_INLINE bool owns (const void *const address)

Additional Inherited Members

- Static Public Attributes inherited from AllocatorStrategyFixedBlock< sizeof(T), O::alignment, locking_traits >
static const size_t block_size
static const size_t alignment
- Protected Member Functions inherited from AllocatorStrategyFixedBlock< sizeof(T), O::alignment, locking_traits >
CC_ALLOCATOR_INLINE void push_front (void *block)
CC_ALLOCATOR_INLINE void * pop_front ()
const size_t pageSize () const
CC_ALLOCATOR_INLINE void allocatePage ()
- Protected Attributes inherited from AllocatorStrategyFixedBlock< sizeof(T), O::alignment, locking_traits >
void * _list
void * _pages
size_t _pageSize
size_t _allocated

Member Typedef Documentation

typedef value_type* pointer
typedef
AllocatorStrategyFixedBlock
<sizeof(T), O::alignment,
locking_traits>
tParentStrategy
typedef T value_type

Constructor & Destructor Documentation

AllocatorStrategyPool ( const char *  tag = nullptr,
size_t  poolSize = 100 
)
inline

Member Function Documentation

CC_ALLOCATOR_INLINE void* allocate ( size_t  size)
inline
CC_ALLOCATOR_INLINE void deallocate ( void *  address,
size_t  size = 0 
)
inline

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