33 template<
class T,
int SizeMin>
36 const labelRange& slice
44 else if (slice.end_value() >= this->size())
47 this->
resize(slice.begin_value());
53 label j = slice.begin_value();
54 const label len = this->size();
56 for (label i = slice.end_value(); i < len; ++i, ++j)
58 Foam::Swap(this->
operator[](i), this->
operator[](j));
61 this->
resize(this->size() - slice.size());
68 template<
class T,
int SizeMin>
71 const labelRange& slice
74 if (slice.begin_value() > 0)
77 label j = slice.begin_value();
78 const label len = slice.
size();
80 for (label i = 0; i < len; ++i, ++j)
82 Foam::Swap(this->
operator[](i), this->
operator[](j));
void size(const label n)
Older name for setAddressableSize.
patchWriters resize(patchIds.size())
A 1D vector of objects of type <T> that resizes itself as necessary to accept the new objects...
void Swap(DynamicList< T, SizeMinA > &a, DynamicList< T, SizeMinB > &b)