59 template<
class ListType>
63 template<
class ListType>
71 template<
class ListType>
79 template<
class ListType>
84 template<
class ListType>
88 template<
class Container>
92 template<
class Container>
101 template<
class T,
class Cmp>
110 template<
class T,
class Cmp>
119 template<
class T,
class Cmp>
125 template<
class T,
class ListType>
126 ListType
subset(
const UList<T>& select,
const T& value,
const ListType&);
131 template<
class T,
class ListType>
132 void inplaceSubset(
const UList<T>& select,
const T& value, ListType&);
138 template<
class BoolListType,
class ListType>
139 ListType
subset(
const BoolListType& select,
const ListType&);
145 template<
class BoolListType,
class ListType>
157 template<
class InList,
class OutList>
161 template<
class InList,
class OutList>
165 invertManyToMany<InList,OutList>(len, in, out);
176 template<
class ListType>
177 label count(
const ListType& l,
typename ListType::const_reference
x);
181 template<
class ListType>
185 typename ListType::const_reference,
190 template<
class ListType>
194 typename ListType::const_reference,
199 template<
class ListType>
204 typename ListType::const_reference
208 template<
class ListType>
212 typename ListType::const_reference initValue,
214 typename ListType::const_reference setValue
219 template<
class ListType>
224 template<
class ListType>
229 template<
class ListType>
233 typename ListType::const_reference,
239 template<
class ListType,
class BinaryOp>
243 typename ListType::const_reference,
250 template<
class ListType>
254 typename ListType::const_reference,
260 template<
class Container,
class T,
int mRows>
265 template<
class Container,
class T,
int mRows,
int nColumns>
269 template<
class ListType>
273 template<
class ListType>
278 template<
class ListType>
282 template<
template<
typename>
class ListType,
class DataType>
286 template<
class BinaryOp>
294 template<
class BinaryOp>
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
List< Container > initList(const T[mRows])
To construct a List from a C array. Has extra Container type.
void inplaceMapValue(const labelUList &oldToNew, Container &)
Map values. Do not map negative values.
List< label > labelList
A List of labels.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
label findMax(const ListType &, const label start=0)
Find index of max element (and larger than given element).
labelList invert(const label len, const labelUList &)
Invert one-to-one map. Unmapped elements will be -1.
ListType reverseList(const ListType &list)
Reverse a list. First element becomes last element etc.
void inplaceReverseList(ListType &list)
Inplace reversal of a list using Swap.
labelList findIndices(const ListType &, typename ListType::const_reference, const label start=0)
Find all occurrences of given element. Linear search.
void duplicateOrder(const UList< T > &, labelList &order)
Generate (sorted) indices corresponding to duplicate list values.
void inplaceMapKey(const labelUList &oldToNew, Container &)
Recreate with mapped keys. Do not map elements with negative key.
label findLower(const ListType &, typename ListType::const_reference, const label stary, const BinaryOp &bop)
Find last element < given value in sorted list and return index,.
int order(const scalar s)
void inplaceSubset(const UList< T > &select, const T &value, ListType &)
Inplace extract elements of List when select is a certain value.
const labelList emptyLabelList
ListType renumber(const labelUList &oldToNew, const ListType &)
Renumber the values (not the indices) of a list.
ListType rotateList(const ListType &list, const label n)
Rotate a list by n places. If n is positive rotate clockwise/right/down.
void inplaceRotateList(ListType< DataType > &list, label n)
Inplace reversal of a list using the Reversal Block Swapping algorithm.
labelListList invertOneToMany(const label len, const labelUList &)
Invert one-to-many map. Unmapped elements will be size 0.
ListType reorder(const label size, const typename ListType::value_type &defaultValue, const labelUList &oldToNew, const ListType &lst)
List< labelList > labelListList
A List of labelList.
label findSortedIndex(const ListType &, typename ListType::const_reference, const label start=0)
Find first occurrence of given element in sorted list and return index,.
void inplaceRenumber(const labelUList &oldToNew, ListType &)
Inplace renumber the values of a list.
static const List< Type > & emptyList()
Return reference to zero-sized list. Compare to List::null() which returns.
label findMin(const ListType &, const label start=0)
Find index of min element (and less than given element).
label findIndex(const ListType &, typename ListType::const_reference, const label start=0)
Find first occurrence of given element and return index,.
List< Container > initListList(const T[mRows][nColumns])
To construct a (square) ListList from a C array. Has extra Container type.
void uniqueOrder(const UList< T > &, labelList &order)
Generate (sorted) indices corresponding to unique list values.
label count(const ListType &l, typename ListType::const_reference x)
Count the number of occurrences of a value in a list.
labelList identityMap(const label len)
Create identity map (map[i] == i) of given length.
void sortedOrder(const UList< T > &, labelList &order)
Generate the (stable) sort order for the list.
UList< label > labelUList
void setValues(ListType &, const labelUList &indices, typename ListType::const_reference)
Opposite of findIndices: set values at indices to given value.
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
ListType createWithValues(const label sz, typename ListType::const_reference initValue, const labelUList &indices, typename ListType::const_reference setValue)
Opposite of findIndices: set values at indices to given value.
ListType subset(const UList< T > &select, const T &value, const ListType &)
Extract elements of List when select is a certain value.
void invertManyToMany(const label len, const UList< InList > &, List< OutList > &)
Invert many-to-many.
void inplaceReorder(const labelUList &oldToNew, ListType &)
Inplace reorder the elements of a list.
Combination-Reduction operation for a parallel run.
List operator to append one list onto another.
void operator()(List< T > &x, const List< T > &y) const
Operator to apply a binary-equals operation to a pair of lists.
void operator()(List< Type > &a, const List< Type > &b) const
Operator to apply a binary operation to a pair of lists.
List< Type > operator()(const List< Type > &a, const List< Type > &b) const