Go to the documentation of this file.
46 #ifndef SortableList_H
47 #define SortableList_H
104 template<class InputIterator>
105 inline
SortableList(InputIterator begIter, InputIterator endIter);
167 void operator=(std::initializer_list<T> lst);
176 inline void Swap(SortableList<T>& a, SortableList<T>&
b);
List< label > labelList
A List of labels.
void sort()
Forward (stable) sort the list (if changed after construction).
List< T > values(const HashTable< T, Key, Hash > &tbl, const bool doSort=false)
List of values from HashTable, optionally sorted.
void reverseSort()
Reverse (stable) sort the list.
void Swap(DynamicList< T, SizeMin1 > &a, DynamicList< T, SizeMin2 > &b)
void partialSort(label n, label start=0)
Forward partial sort the list until the middle point.
labelList & indices()
Return non-const access to the sorted indices. Updated every sort.
const dimensionedScalar b
Wien displacement law constant: default SI units: [m.K].
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
void partialReverseSort(label n, label start=0)
Reverse partial sort the list until the middle point.
void operator=(const T &val)
Assignment of all entries to the given value, removing indices.
List< T > & shrink()
Clear the indices and return a reference to the underlying List.
void swap(SortableList< T > &lst)
Swap content with another SortableList in constant time.
A list that is sorted upon construction or when explicitly requested with the sort() method.
constexpr SortableList() noexcept
Null constructor, sort later (eg, after assignment or transfer)
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
const labelList & indices() const
Return the list of sorted indices. Updated every sort.
void clear()
Clear the list and the indices.