#include <Containers/SmallVector.h>
template<class Size_T>
SmallVectorBase class
SmallVector base class
The template parameter specifies the type which should be used to hold the Size and Capacity of SmallVector
, so it can be adjusted. Using 32-bit size is desirable to shrink the size of SmallVector
. Using 64-bit size is desirable for cases like SmallVector<char>
, where a 32 bit size would limit the vector to ~4GB.
Constructors, destructors, conversion operators
- SmallVectorBase() protected deleted
-
SmallVectorBase(void* firstEl,
std::
size_t totalCapacity) protected
Public functions
-
auto size() const -> std::
size_t -
auto capacity() const -> std::
size_t - auto empty() const -> bool
Protected static functions
-
static auto SizeTypeMax() -> std::
size_t constexpr - Maximum value of the
Size_T
used.
Protected functions
-
auto mallocForGrow(void* firstEl,
std::
size_t minSize, std:: size_t typeSize, std:: size_t& newCapacity) -> void* -
void growPod(void* firstEl,
std::
size_t minSize, std:: size_t typeSize) -
auto replaceAllocation(void* newElts,
std::
size_t typeSize, std:: size_t newCapacity, std:: size_t vSize = 0) -> void* -
void set_size(std::
size_t n)