|
Zserio C++17 runtime library 1.3.0
Built for Zserio 2.20.0
|
#include <PropagatingPolymorphicAllocator.h>
Public Types | |
| using | value_type = T |
| using | propagate_on_container_copy_assignment = std::true_type |
| using | propagate_on_container_move_assignment = std::true_type |
| using | propagate_on_container_swap = std::true_type |
Propagating version of the polymorphic allocator. This one is propagated on container copy and assignment.
Definition at line 16 of file PropagatingPolymorphicAllocator.h.
| using zserio::ppmr::PropagatingPolymorphicAllocator< T >::propagate_on_container_copy_assignment = std::true_type |
Definition at line 21 of file PropagatingPolymorphicAllocator.h.
| using zserio::ppmr::PropagatingPolymorphicAllocator< T >::propagate_on_container_move_assignment = std::true_type |
Definition at line 22 of file PropagatingPolymorphicAllocator.h.
| using zserio::ppmr::PropagatingPolymorphicAllocator< T >::propagate_on_container_swap = std::true_type |
Definition at line 23 of file PropagatingPolymorphicAllocator.h.
| using zserio::ppmr::PropagatingPolymorphicAllocator< T >::value_type = T |
Definition at line 19 of file PropagatingPolymorphicAllocator.h.
|
inlinenoexcept |
Constructor.
Note that this is intentionally non-explicit to allow to pass MemoryResource wherever the PropagatingPolymorphicAllocator is required.
| resource | Memory resource. According to the C++ standard the resource may not be NULL. Since it implies undefined behaviour, we define a non-standard extension here. When the resource is NULL, std::pmr::get_default_resource() is used instead! |
Definition at line 35 of file PropagatingPolymorphicAllocator.h.
|
default |
Method generated by default.
|
defaultnoexcept |
Method generated by default.
|
defaultnoexcept |
Method generated by default.
|
inlinenoexcept |
Copy constructor from PropagatingPolymorphicAllocator with another value_type.
| other | Other PropagatingPolymorphicAllocator. |
Definition at line 62 of file PropagatingPolymorphicAllocator.h.
|
inline |
Allocates memory for n values.
| size | Number of values to allocate memory for. |
Definition at line 82 of file PropagatingPolymorphicAllocator.h.
|
inline |
Constructs an object in allocated memory.
| ptr | Pointer to memory where the object will be constructed. |
| args | Parameters to be forwarded to the object constructor. |
Definition at line 106 of file PropagatingPolymorphicAllocator.h.
|
inlinenoexcept |
Deallocates memory for n values.
| memory | Pointer to the memory to deallocate. |
| size | Number of values held by the memory pointed to by memory. Shall be the same size as was used for allocation of memory. |
Definition at line 94 of file PropagatingPolymorphicAllocator.h.
|
inlinenoexcept |
Destroys an object
| ptr | Pointer to the object to be destroyed. |
Definition at line 132 of file PropagatingPolymorphicAllocator.h.
|
defaultnoexcept |
Method generated by default.
|
inlinenoexcept |
Assignment operator from PropagatingPolymorphicAllocator with another value_type.
| other | Other PropagatingPolymorphicAllocator. |
Definition at line 72 of file PropagatingPolymorphicAllocator.h.
|
defaultnoexcept |
Method generated by default.
|
inlinenoexcept |
Gets the underlying memory resource.
Definition at line 148 of file PropagatingPolymorphicAllocator.h.
|
inline |
Returns instance of the allocator to be used when a container gets copied.
Definition at line 140 of file PropagatingPolymorphicAllocator.h.