Lagrange
SmallVector< T, N > Class Template Reference

Hybrid vector that uses the stack upto a maximum size, and the heap beyond that. More...

#include <lagrange/utils/SmallVector.h>

Inherits vector< T, SmallBufferAllocator< T, 8 > >.

Public Member Functions

 SmallVector (const SmallVector &)=default
 
SmallVectoroperator= (const SmallVector &)=default
 
 SmallVector (SmallVector &&other) noexcept(std::is_nothrow_move_constructible< T >::value)
 
SmallVectoroperator= (SmallVector &&other) noexcept(std::is_nothrow_move_constructible< T >::value)
 
 SmallVector (std::size_t count)
 
 SmallVector (std::size_t count, const T &value)
 
template<class InputIt >
 SmallVector (InputIt first, InputIt last)
 
 SmallVector (std::initializer_list< T > init)
 

Detailed Description

template<typename T, std::size_t N = 8>
class lagrange::SmallVector< T, N >

Hybrid vector that uses the stack upto a maximum size, and the heap beyond that.

This class is derived from std::vector<>, so any public method available for a std::vector<> can be used here.

Template Parameters
TValue type.
NMaximum size.
Note
From https://github.com/KonanM/small_vector, renamed and formatted to be consistent with Lagrange conventions.

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