Jolt Physics
A multi core friendly Game Physics Engine
Loading...
Searching...
No Matches
STLTempAllocator< T > Class Template Reference

STL allocator that wraps around TempAllocator. More...

#include <STLTempAllocator.h>

Classes

struct  rebind
 Converting to allocator for other type. More...
 

Public Types

using value_type = T
 
using pointer = T *
 Pointer to type. More...
 
using const_pointer = const T *
 
using reference = T &
 
using const_reference = const T &
 
using size_type = size_t
 
using difference_type = ptrdiff_t
 

Public Member Functions

 STLTempAllocator (TempAllocator &inAllocator)
 Constructor. More...
 
template<typename T2 >
 STLTempAllocator (const STLTempAllocator< T2 > &inRHS)
 Constructor from other allocator. More...
 
pointer allocate (size_type inN)
 Allocate memory. More...
 
void deallocate (pointer inPointer, size_type inN)
 Free memory. More...
 
bool operator== (const STLTempAllocator< T > &) const
 Allocators are stateless so assumed to be equal. More...
 
bool operator!= (const STLTempAllocator< T > &) const
 
TempAllocatorGetAllocator () const
 Get our temp allocator. More...
 

Detailed Description

template<typename T>
class STLTempAllocator< T >

STL allocator that wraps around TempAllocator.

Member Typedef Documentation

◆ const_pointer

template<typename T >
using STLTempAllocator< T >::const_pointer = const T *

◆ const_reference

template<typename T >
using STLTempAllocator< T >::const_reference = const T &

◆ difference_type

template<typename T >
using STLTempAllocator< T >::difference_type = ptrdiff_t

◆ pointer

template<typename T >
using STLTempAllocator< T >::pointer = T *

Pointer to type.

◆ reference

template<typename T >
using STLTempAllocator< T >::reference = T &

Reference to type. Can be removed in C++20.

◆ size_type

template<typename T >
using STLTempAllocator< T >::size_type = size_t

◆ value_type

template<typename T >
using STLTempAllocator< T >::value_type = T

Constructor & Destructor Documentation

◆ STLTempAllocator() [1/2]

template<typename T >
STLTempAllocator< T >::STLTempAllocator ( TempAllocator inAllocator)
inline

Constructor.

◆ STLTempAllocator() [2/2]

template<typename T >
template<typename T2 >
STLTempAllocator< T >::STLTempAllocator ( const STLTempAllocator< T2 > &  inRHS)
inlineexplicit

Constructor from other allocator.

Member Function Documentation

◆ allocate()

template<typename T >
pointer STLTempAllocator< T >::allocate ( size_type  inN)
inline

Allocate memory.

◆ deallocate()

template<typename T >
void STLTempAllocator< T >::deallocate ( pointer  inPointer,
size_type  inN 
)
inline

Free memory.

◆ GetAllocator()

template<typename T >
TempAllocator & STLTempAllocator< T >::GetAllocator ( ) const
inline

Get our temp allocator.

◆ operator!=()

template<typename T >
bool STLTempAllocator< T >::operator!= ( const STLTempAllocator< T > &  ) const
inline

◆ operator==()

template<typename T >
bool STLTempAllocator< T >::operator== ( const STLTempAllocator< T > &  ) const
inline

Allocators are stateless so assumed to be equal.


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