8 template <
class T,
class Allocator>
20 NiTArray(std::uint32_t a_maxSize = 0, std::uint32_t a_growBy = 1) :
22 _capacity(static_cast<
std::uint16_t>(a_maxSize)),
25 _growthSize(static_cast<
std::uint16_t>(a_growBy))
86 return _data + _capacity;
91 return _data + _capacity;
96 return _data + _capacity;
99 [[nodiscard]]
bool empty()
const
101 return _capacity == 0;
117 std::uint16_t _capacity;
118 std::uint16_t _freeIdx;
120 std::uint16_t _growthSize;
122 static_assert(
sizeof(NiTArray<
void*, NiTMallocInterface<void*>>) == 0x18);
132 static_assert(
sizeof(NiTObjectArray<void*>) == 0x18);
142 static_assert(
sizeof(NiTPrimitiveArray<void*>) == 0x18);
144 template <
class T,
class Allocator>
158 _capacity(a_maxSize),
161 _growthSize(a_growBy)
175 assert(a_pos <
size());
181 assert(a_pos <
size());
222 return _data + _size;
227 return _data + _size;
232 return _data + _size;
237 return _capacity == 0;
253 std::uint32_t _capacity;
254 std::uint32_t _freeIdx;
256 std::uint32_t _growthSize;
258 static_assert(
sizeof(NiTLargeArray<
void*, NiTMallocInterface<void*>>) == 0x20);
268 static_assert(
sizeof(NiTLargeObjectArray<void*>) == 0x20);
278 static_assert(
sizeof(NiTLargePrimitiveArray<void*>) == 0x20);
Definition: NiTArray.h:10
virtual ~NiTArray()
Definition: NiTArray.h:32
T * iterator
Definition: NiTArray.h:17
const_iterator cend() const
Definition: NiTArray.h:94
const_iterator end() const
Definition: NiTArray.h:89
NiTArray(std::uint32_t a_maxSize=0, std::uint32_t a_growBy=1)
Definition: NiTArray.h:20
const_reference operator[](size_type a_pos) const
Definition: NiTArray.h:43
reference front()
Definition: NiTArray.h:49
const value_type & const_reference
Definition: NiTArray.h:16
iterator begin()
Definition: NiTArray.h:69
Allocator allocator_type
Definition: NiTArray.h:13
bool empty() const
Definition: NiTArray.h:99
reference back()
Definition: NiTArray.h:59
iterator end()
Definition: NiTArray.h:84
const_reference front() const
Definition: NiTArray.h:54
std::uint16_t size_type
Definition: NiTArray.h:14
reference operator[](size_type a_pos)
Definition: NiTArray.h:37
T value_type
Definition: NiTArray.h:12
const T * const_iterator
Definition: NiTArray.h:18
const_reference back() const
Definition: NiTArray.h:64
const_iterator cbegin() const
Definition: NiTArray.h:79
value_type & reference
Definition: NiTArray.h:15
size_type capacity() const
Definition: NiTArray.h:109
size_type size() const
Definition: NiTArray.h:104
const_iterator begin() const
Definition: NiTArray.h:74
Definition: NiTArray.h:146
size_type capacity() const
Definition: NiTArray.h:245
value_type & reference
Definition: NiTArray.h:151
reference back()
Definition: NiTArray.h:195
reference front()
Definition: NiTArray.h:185
const_reference operator[](size_type a_pos) const
Definition: NiTArray.h:179
const value_type & const_reference
Definition: NiTArray.h:152
const_reference front() const
Definition: NiTArray.h:190
T value_type
Definition: NiTArray.h:148
std::uint32_t size_type
Definition: NiTArray.h:150
const T * const_iterator
Definition: NiTArray.h:154
const_iterator cend() const
Definition: NiTArray.h:230
iterator end()
Definition: NiTArray.h:220
const_reference back() const
Definition: NiTArray.h:200
const_iterator cbegin() const
Definition: NiTArray.h:215
Allocator allocator_type
Definition: NiTArray.h:149
virtual ~NiTLargeArray()
Definition: NiTArray.h:168
const_iterator begin() const
Definition: NiTArray.h:210
reference operator[](size_type a_pos)
Definition: NiTArray.h:173
iterator begin()
Definition: NiTArray.h:205
const_iterator end() const
Definition: NiTArray.h:225
NiTLargeArray(std::uint32_t a_maxSize=0, std::uint32_t a_growBy=1)
Definition: NiTArray.h:156
size_type size() const
Definition: NiTArray.h:240
bool empty() const
Definition: NiTArray.h:235
T * iterator
Definition: NiTArray.h:153
Definition: NiTArray.h:262
NiTLargeObjectArray(std::uint32_t a_maxSize=0, std::uint32_t a_growBy=1)
Definition: NiTArray.h:264
Definition: NiTArray.h:272
NiTLargePrimitiveArray(std::uint32_t a_maxSize=0, std::uint32_t a_growBy=1)
Definition: NiTArray.h:274
Definition: NiTCollection.h:32
Definition: NiTCollection.h:47
Definition: NiTArray.h:126
NiTObjectArray(std::uint32_t a_maxSize=0, std::uint32_t a_growBy=1)
Definition: NiTArray.h:128
Definition: NiTArray.h:136
NiTPrimitiveArray(std::uint32_t a_maxSize=0, std::uint32_t a_growBy=1)
Definition: NiTArray.h:138
constexpr REL::ID Allocate(static_cast< std::uint64_t >(66859))
constexpr REL::ID Deallocate(static_cast< std::uint64_t >(66861))
Definition: AbsorbEffect.h:6
Definition: EffectArchetypes.h:65