ALib C++ Library
Library Version: 2412 R0
Documentation generated by doxygen
Loading...
Searching...
No Matches
SharedVal< T, TAllocator >::FieldMembersNoTA Struct Reference

Description:

template<typename T, typename TAllocator = HeapAllocator>
struct alib::containers::SharedVal< T, TAllocator >::FieldMembersNoTA

Fields if TAllocator is default constructible (e.g., HeapAllocator).

Definition at line 69 of file sharedval.hpp.

#include <sharedval.hpp>

Collaboration diagram for SharedVal< T, TAllocator >::FieldMembersNoTA:
[legend]

Public Static Method Index:

static constexpr TAllocator GetAllocator () noexcept
 

Public Field Index:

custom
 The instance of the custom type.
 
std::atomic< unsigned int > refCount
 The reference counter used to implement the std::shared_ptr behavior.
 

Public Method Index:

template<typename... TArgs, typename TEnableIf = TAllocator, ATMP_IF(std::is_default_constructible< TEnableIf >::value) >
 FieldMembersNoTA (TArgs &&... args)
 

Field Details:

◆ custom

template<typename T , typename TAllocator = HeapAllocator>
T custom

The instance of the custom type.

Definition at line 72 of file sharedval.hpp.

◆ refCount

template<typename T , typename TAllocator = HeapAllocator>
std::atomic<unsigned int> refCount

The reference counter used to implement the std::shared_ptr behavior.

Definition at line 75 of file sharedval.hpp.

Constructor(s) / Destructor Details:

◆ FieldMembersNoTA()

template<typename T , typename TAllocator = HeapAllocator>
template<typename... TArgs, typename TEnableIf = TAllocator, ATMP_IF(std::is_default_constructible< TEnableIf >::value) >
FieldMembersNoTA ( TArgs &&... args)
inline

Alternative constructor missing the allocator instance. This is used only with allocators that are default constructible (like HeapAllocator is).

Template Parameters
TArgsThe argument types used for constructing T.
Parameters
argsThe arguments for constructing T.

Definition at line 84 of file sharedval.hpp.

Method Details:

◆ GetAllocator()

template<typename T , typename TAllocator = HeapAllocator>
static constexpr TAllocator GetAllocator ( )
inlinestaticconstexprnoexcept
Returns
A heap allocator value.

Definition at line 89 of file sharedval.hpp.


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