59 template<
class ListType>
64 template<
class ListType>
70 template<
class ListType>
75 template<
class ListType>
83 template<
class Container>
87 template<
class Container>
95 template<
class T,
class Cmp>
102 template<
class T,
class Cmp>
109 template<
class T,
class Cmp>
115 template<
class T,
class ListType>
116 ListType
subset(
const UList<T>& select,
const T& value,
const ListType&);
121 template<
class T,
class ListType>
128 template<
class BoolListType,
class ListType>
129 ListType
subset(
const BoolListType& select,
const ListType&);
135 template<
class BoolListType,
class ListType>
147 template<
class InList,
class OutList>
150 template<
class InList,
class OutList>
154 invertManyToMany<InList,OutList>(len, in, out);
163 template<
class ListType>
167 typename ListType::const_reference,
172 template<
class ListType>
176 typename ListType::const_reference,
181 template<
class ListType>
186 typename ListType::const_reference
190 template<
class ListType>
194 typename ListType::const_reference initValue,
196 typename ListType::const_reference setValue
201 template<
class ListType>
207 template<
class ListType>
213 template<
class ListType>
217 typename ListType::const_reference,
224 template<
class ListType,
class BinaryOp>
228 typename ListType::const_reference,
236 template<
class ListType>
240 typename ListType::const_reference,
247 template<
class Container,
class T,
int mRows>
253 template<
class Container,
class T,
int mRows,
int nColumns>
267 template<
class ListType>
272 template<
class ListType>
278 template<
class ListType>
283 template<
template<
typename>
class ListType,
class DataType>
void inplaceSubset(const UList< T > &select, const T &value, ListType &)
Inplace extract elements of List when select is a certain value.
void inplaceMapKey(const labelUList &oldToNew, Container &)
Recreate with mapped keys. Do not map elements with negative key.
ListType renumber(const labelUList &oldToNew, const ListType &)
Renumber the values (not the indices) of a list.
void duplicateOrder(const UList< T > &, labelList &order)
Generate (sorted) indices corresponding to duplicate list values.
void inplaceReorder(const labelUList &oldToNew, ListType &)
Inplace reorder the elements of a list.
label findSortedIndex(const ListType &, typename ListType::const_reference, const label start=0)
Find first occurrence of given element in sorted list and return index,.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
void sortedOrder(const UList< T > &, labelList &order)
Generate the (stable) sort order for the list.
void inplaceRenumber(const labelUList &oldToNew, ListType &)
Inplace renumber the values 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.
labelListList invertOneToMany(const label len, const labelUList &)
Invert one-to-many map. Unmapped elements will be size 0.
void uniqueOrder(const UList< T > &, labelList &order)
Generate (sorted) indices corresponding to unique list values.
Combination-Reduction operation for a parallel run.
List< Container > initList(const T[mRows])
To construct a List from a C array. Has extra Container type.
void setValues(ListType &, const labelUList &indices, typename ListType::const_reference)
Opposite of findIndices: set values at indices to given value.
labelList identity(const label len)
Create identity map (map[i] == i) of given length.
label findMin(const ListType &, const label start=0)
Find index of min element (and less than given element).
labelList findIndices(const ListType &, typename ListType::const_reference, const label start=0)
Find all occurrences of given element. Linear search.
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.
void inplaceReverseList(ListType &list)
Inplace reversal of a list using Swap.
labelList invert(const label len, const labelUList &)
Invert one-to-one map. Unmapped elements will be -1.
void operator()(List< T > &x, const List< T > &y) const
static const List< Type > & emptyList()
Return reference to zero-sized list. Compare to List::null() which returns.
List< label > labelList
A List of labels.
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
ListType reverseList(const ListType &list)
Reverse a list. First element becomes last element etc.
label findMax(const ListType &, const label start=0)
Find index of max element (and larger than given element).
ListType reorder(const labelUList &oldToNew, const ListType &)
Reorder the elements (indices, not values) of a list.
List< Container > initListList(const T[mRows][nColumns])
To construct a (square) ListList from a C array. Has extra Container type.
void inplaceMapValue(const labelUList &oldToNew, Container &)
Map values. Do not map negative values.
label findIndex(const ListType &, typename ListType::const_reference, const label start=0)
Find first occurrence of given element and return index,.
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
const labelList emptyLabelList
void inplaceRotateList(ListType< DataType > &list, label n)
Inplace reversal of a list using the Reversal Block Swapping algorithm.
void invertManyToMany(const label len, const UList< InList > &, List< OutList > &)
Invert many-to-many.
ListType subset(const UList< T > &select, const T &value, const ListType &)
Extract elements of List when select is a certain value.
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,.
Helper class for list to append y onto the end of x.