|
ADS
Algorithms and Data Structures
|
the standard allocator of objects of type T over the resource R More...
#include <ADS/memory/PoolAllocator.h>
Classes | |
| struct | rebind |
| the allocator of the objects of type U over the same resource More... | |
Public types | |
| using | value_type = T |
| the objects | |
| using | size_type = std::size_t |
| a number of objects | |
| using | difference_type = std::ptrdiff_t |
| a distance in objects | |
| using | propagate_on_container_copy_assignment = std::true_type |
| the allocator copied with the container | |
| using | propagate_on_container_move_assignment = std::true_type |
| the allocator moved with the container | |
| using | propagate_on_container_swap = std::true_type |
| the allocator swapped with the container | |
| using | is_always_equal = std::false_type |
| two allocators are equal only if they share their resource | |
Public member functions | |
| PoolAllocator (R &r) noexcept | |
| the allocator of the resource r | |
| PoolAllocator (void) noexcept | |
| the allocator of the default resource of R, if it has one | |
| template<class U> | |
| PoolAllocator (const PoolAllocator< U, R > &o) noexcept | |
| the allocator of the resource of \( o \), for objects of type T | |
| T * | allocate (std::size_t n) |
| room for \( n \) objects, the class found at compile time when \( n = 1 \) | |
| void | deallocate (T *p, std::size_t n) |
| the room \( p \) of \( n \) objects given back | |
| R * | resource (void) const noexcept |
| the resource | |
| template<class U> | |
| bool | operator== (const PoolAllocator< U, R > &o) const noexcept |
| whether the two share their resource | |
the standard allocator of objects of type T over the resource R
| using ADS::PoolAllocator< T, R >::difference_type = std::ptrdiff_t |
a distance in objects
| using ADS::PoolAllocator< T, R >::is_always_equal = std::false_type |
two allocators are equal only if they share their resource
| using ADS::PoolAllocator< T, R >::propagate_on_container_copy_assignment = std::true_type |
the allocator copied with the container
| using ADS::PoolAllocator< T, R >::propagate_on_container_move_assignment = std::true_type |
the allocator moved with the container
| using ADS::PoolAllocator< T, R >::propagate_on_container_swap = std::true_type |
the allocator swapped with the container
| using ADS::PoolAllocator< T, R >::size_type = std::size_t |
a number of objects
| using ADS::PoolAllocator< T, R >::value_type = T |
the objects
|
inlinenoexcept |
the allocator of the resource r
|
inlinenoexcept |
the allocator of the default resource of R, if it has one
|
inlinenoexcept |
the allocator of the resource of \( o \), for objects of type T
|
nodiscard |
room for \( n \) objects, the class found at compile time when \( n = 1 \)
| void ADS::PoolAllocator< T, R >::deallocate | ( | T * | p, |
| std::size_t | n ) |
the room \( p \) of \( n \) objects given back
|
inlinenoexcept |
whether the two share their resource
|
inlinenodiscardnoexcept |
the resource