Go to the documentation of this file.
45 #include <type_traits>
55 template<
class T,
int SizeMin>
class PtrDynList;
61 template<
class T,
int SizeMin=64>
66 static_assert(SizeMin > 0,
"Invalid min size parameter");
103 inline label
capacity()
const noexcept;
107 inline const T*
get(
const label i)
const;
112 const T*
set(
const label i)
const {
return this->
get(i); }
118 inline void reserve(
const label len);
121 inline void resize(
const label newLen);
152 template<
int AnySizeMin>
156 template<class... Args>
169 inline
void append(std::unique_ptr<
T>&& ptr);
181 template<
int AnySizeMin>
188 template<class... Args>
201 inline
autoPtr<
T>
set(const label i, std::unique_ptr<
T>&& ptr);
216 inline
void operator=(const
PtrList<
T>& list);
219 inline
void operator=(const
PtrDynList<
T, SizeMin>& list);
222 template<
int AnySizeMin>
223 inline
void operator=(const
PtrDynList<
T, AnySizeMin>& list);
226 inline
void operator=(
PtrList<
T>&& list);
229 inline
void operator=(
PtrDynList<
T, SizeMin>&& list);
232 template<
int AnySizeMin>
233 inline
void operator=(
PtrDynList<
T, AnySizeMin>&& list);
243 #include "PtrDynListI.H"
const T * set(const label i) const
void swap(PtrDynList< T, AnySizeMin > &other)
A class for managing temporary objects.
label expandStorage() noexcept
label capacity() const noexcept
void reorder(const labelUList &oldToNew)
A dynamically resizable PtrList with allocation management.
void resize(const label newLen)
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
A list of pointers to objects of type <T>, with allocation/deallocation management of the pointers....
void setSize(const label n)
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
autoPtr< T > emplace(const label i, Args &&... args)
constexpr PtrDynList() noexcept
void emplace_append(Args &&... args)
void reserve(const label len)
Foam::argList args(argc, argv)
const T * get(const label i) const
A class for managing references or pointers (no reference counting)