121template<
class UnaryCondition>
125 const UnaryCondition& select,
129 const label len = values.size();
134 addr.resize_nocopy(len);
137 for (label i=0; i < len; ++i)
153template<
class UnaryPredicate>
157 const UnaryPredicate& pred,
161 const label len = values.size();
166 addr.resize_nocopy(len);
169 for (label i=0; i < len; ++i)
191 const label len = values.size();
202 for (label i = 1; i < len; ++i)
205 if (values[order[count]] != values[order[i]])
208 order[count] = order[i];
A class for storing list addressing (labels, slices etc), which are normally to used by IndirectList....
A List with indirect addressing.
static IndirectList< T > subset_if(const UList< T > &values, const UnaryPredicate &pred, const bool invert=false)
static IndirectList< T > subset(const UList< T > &values, const UnaryCondition &select, const bool invert=false)
A List with indirect addressing. Like IndirectList but does not store addressing.
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
A class representing the concept of 0 (zero) that can be used to avoid manipulating objects known to ...
labelList sortedOrder(const UList< T > &input)
Return the (stable) sort order for the list.
void sort(UList< T > &list)
Sort the list.
labelList invert(const label len, const labelUList &map)
Create an inverse one-to-one mapping.