LibSWOC++ 1.5.14
Solid Wall of C++
Loading...
Searching...
No Matches
swoc::Vectray< T, N, A >::FixedStore Struct Reference

Internal (fixed) storage. More...

#include <Vectray.h>

Collaboration diagram for swoc::Vectray< T, N, A >::FixedStore:
Collaboration graph

Public Member Functions

 FixedStore ()=default
 Default construct - empty.
 
 FixedStore (allocator_type const &a)
 
MemSpan< T > span ()
 
T * data ()
 
T const * data () const
 

Public Attributes

std::array< std::byte, sizeof(T) *N > _raw
 Raw memory for element storage.
 
size_t _count = 0
 Number of valid elements.
 
allocator_type _a
 Allocator instance - used for construction.
 

Detailed Description

template<typename T, size_t N, class A = std::allocator<T>>
struct swoc::Vectray< T, N, A >::FixedStore

Internal (fixed) storage.

Definition at line 54 of file Vectray.h.

Constructor & Destructor Documentation

◆ FixedStore()

template<typename T, size_t N, class A = std::allocator<T>>
swoc::Vectray< T, N, A >::FixedStore::FixedStore ( allocator_type const & a)
inlineexplicit

Construct with specific allocator a.

Parameters
aAllocator.

Definition at line 65 of file Vectray.h.

◆ ~FixedStore()

template<typename T, size_t N, class A>
swoc::Vectray< T, N, A >::FixedStore::~FixedStore ( )

Definition at line 257 of file Vectray.h.

Member Function Documentation

◆ data() [1/2]

template<typename T, size_t N, class A>
T * swoc::Vectray< T, N, A >::FixedStore::data ( )
Returns
A pointer to the data.

Definition at line 271 of file Vectray.h.

◆ data() [2/2]

template<typename T, size_t N, class A>
T const * swoc::Vectray< T, N, A >::FixedStore::data ( ) const
Returns
A pointer to the data.

Definition at line 277 of file Vectray.h.

◆ span()

template<typename T, size_t N, class A>
MemSpan< T > swoc::Vectray< T, N, A >::FixedStore::span ( )
Returns
A span containing the valid elements.

Definition at line 265 of file Vectray.h.

Member Data Documentation

◆ _a

template<typename T, size_t N, class A = std::allocator<T>>
allocator_type swoc::Vectray< T, N, A >::FixedStore::_a

Allocator instance - used for construction.

Definition at line 57 of file Vectray.h.

◆ _count

template<typename T, size_t N, class A = std::allocator<T>>
size_t swoc::Vectray< T, N, A >::FixedStore::_count = 0

Number of valid elements.

Definition at line 56 of file Vectray.h.

◆ _raw

template<typename T, size_t N, class A = std::allocator<T>>
std::array<std::byte, sizeof(T) * N> swoc::Vectray< T, N, A >::FixedStore::_raw

Raw memory for element storage.

Definition at line 55 of file Vectray.h.


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