zpp
Zephyr C++20 Framework
|
A memory slab class. More...
#include <mem_slab.hpp>
Public Member Functions | |
mem_slab () noexcept | |
Default constructor. More... | |
constexpr auto | native_handle () noexcept -> native_pointer |
get the native zephyr mem slab handle. More... | |
constexpr auto | native_handle () const noexcept -> native_const_pointer |
get the native zephyr mem slab handle. More... | |
mem_slab (const mem_slab &)=delete | |
mem_slab (mem_slab &&)=delete | |
mem_slab & | operator= (const mem_slab &)=delete |
mem_slab & | operator= (mem_slab &&)=delete |
Public Member Functions inherited from zpp::mem_slab_base< mem_slab< T_BlockSize, T_BlockCount, sizeof(void *) > > | |
mem_slab_base (const mem_slab_base &)=delete | |
mem_slab_base (mem_slab_base &&)=delete | |
void * | allocate () noexcept |
allocate a memory block, waiting forever More... | |
void * | try_allocate () noexcept |
try allocate a memory block, not waiting More... | |
void * | try_allocate_for (const std::chrono::duration< T_Rep, T_Period > &timeout) noexcept |
try allocate a memory block waiting with a timeout More... | |
void | deallocate (void *vp) noexcept |
deallocate memory More... | |
constexpr auto | block_size () const noexcept |
the size of the memory blocks More... | |
constexpr auto | total_block_count () const noexcept |
get maximm number of blocks that can be allocated More... | |
constexpr auto | used_block_count () noexcept |
get current number of used blocks More... | |
constexpr auto | free_block_count () noexcept |
get current number of free blocks More... | |
auto | native_handle () noexcept -> native_pointer |
get the native zephyr mem slab handle. More... | |
auto | native_handle () const noexcept -> native_const_pointer |
get the native zephyr mem slab handle. More... | |
mem_slab_base & | operator= (const mem_slab_base &)=delete |
mem_slab_base & | operator= (mem_slab_base &&)=delete |
Additional Inherited Members | |
Public Types inherited from zpp::mem_slab_base< mem_slab< T_BlockSize, T_BlockCount, sizeof(void *) > > | |
using | native_type = struct k_mem_slab |
using | native_pointer = native_type * |
using | native_const_pointer = native_type const * |
Protected Member Functions inherited from zpp::mem_slab_base< mem_slab< T_BlockSize, T_BlockCount, sizeof(void *) > > | |
constexpr | mem_slab_base () noexcept |
A memory slab class.
Definition at line 181 of file mem_slab.hpp.
|
inlinenoexcept |
Default constructor.
Definition at line 197 of file mem_slab.hpp.
|
delete |
|
delete |
|
inlineconstexprnoexcept |
get the native zephyr mem slab handle.
Definition at line 217 of file mem_slab.hpp.
|
inlineconstexprnoexcept |
get the native zephyr mem slab handle.
Definition at line 207 of file mem_slab.hpp.
|
delete |
|
delete |