AGX Dynamics 2.42.1.1
Loading...
Searching...
No Matches
agx::Allocator< T > Class Template Reference

Templated allocator. More...

#include <Allocator.h>

+ Inheritance diagram for agx::Allocator< T >:

Public Member Functions

 Allocator (const char *name="Allocator")
 
T * allocate (size_t numElements)
 Allocate/deallocate raw memory.
 
void deallocate (T *buffer)
 
- Public Member Functions inherited from agx::ByteAllocator
 ByteAllocator (const ByteAllocator &other)
 
 ByteAllocator (const char *name="ByteAllocator")
 
void * allocateBytes (size_t numBytes, size_t alignment=16)
 Allocate a memory section of specified alignment.
 
void deallocateBytes (void *buffer)
 
void deallocateBytes (void *buffer, size_t numBytes)
 Deallocate a section previously allocated using allocateBytes method.
 
const char * getName () const
 
ByteAllocatoroperator= (const ByteAllocator &other)
 
void setContainer (class Container *)
 

Additional Inherited Members

- Static Public Member Functions inherited from agx::ByteAllocator
static void initMemory (void *data, size_t numBytes, agx::UInt32 pattern)
 
static void * standaloneAllocateBytes (size_t numBytes, size_t alignment=16)
 
static void standaloneDeallocateTypes (void *buffer)
 
- Static Public Attributes inherited from agx::ByteAllocator
static agx::UInt32 allocatedMemoryPattern
 
static agx::UInt32 deallocatedMemoryPattern
 
static bool initMemoryFlag
 

Detailed Description

template<typename T>
class agx::Allocator< T >

Templated allocator.

Definition at line 106 of file Allocator.h.

Constructor & Destructor Documentation

◆ Allocator()

template<typename T >
agx::Allocator< T >::Allocator ( const char *  name = "Allocator< T >")
inline

Definition at line 179 of file Allocator.h.

Member Function Documentation

◆ allocate()

template<typename T >
T * agx::Allocator< T >::allocate ( size_t  numElements)

Allocate/deallocate raw memory.

Definition at line 185 of file Allocator.h.

References agx::ByteAllocator::allocateBytes().

◆ deallocate()

template<typename T >
void agx::Allocator< T >::deallocate ( T *  buffer)

Definition at line 191 of file Allocator.h.

References agx::ByteAllocator::deallocateBytes().


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