template<typename Item>
class pw::containers::internal::GenericIntrusiveList< Item >
Generic intrusive list implementation.
This implementation relies on the Item
type to provide details of how to navigate the list. It provides methods similar to std::forward_list
and std::list
.
- Template Parameters
-
Item | The type used to intrusive store list pointers. |
|
template<typename Iterator > |
| GenericIntrusiveList (Iterator first, Iterator last) |
|
| GenericIntrusiveList (const GenericIntrusiveList &)=delete |
|
GenericIntrusiveList & | operator= (const GenericIntrusiveList &)=delete |
|
| GenericIntrusiveList (GenericIntrusiveList &&other) |
|
GenericIntrusiveList & | operator= (GenericIntrusiveList &&other) |
|
template<typename Iterator > |
void | assign (Iterator first, Iterator last) |
|
constexpr Item * | before_begin () noexcept |
| Returns a pointer to the sentinel item.
|
|
constexpr const Item * | before_begin () const noexcept |
|
constexpr Item * | begin () noexcept |
| Returns a pointer to the first item.
|
|
constexpr const Item * | begin () const noexcept |
|
Item * | before_end () noexcept |
| Returns a pointer to the last item.
|
|
constexpr Item * | end () noexcept |
| Returns a pointer to the sentinel item.
|
|
constexpr const Item * | end () const noexcept |
|
bool | empty () const noexcept |
|
constexpr size_t | max_size () const noexcept |
|
void | clear () |
| Removes all items from the list.
|
|
void | swap (GenericIntrusiveList< Item > &other) |
|
template<typename Compare > |
void | merge (GenericIntrusiveList< Item > &other, Compare comp) |
|
bool | remove (const Item &item_to_remove) |
|
template<typename UnaryPredicate > |
size_t | remove_if (UnaryPredicate pred, size_t max=std::numeric_limits< size_t >::max()) |
|
void | reverse () |
| Reverses the order of items in the list.
|
|
template<typename BinaryPredicate > |
size_t | unique (BinaryPredicate pred) |
|
template<typename Compare > |
void | sort (Compare comp) |
|