__gnu_cxx::slist< _Tp, _Alloc > Class Template Reference
Extensions » SGI

`#include <slist>`

## Public Types

typedef _Base::allocator_type | allocator_type
typedef _Slist_iterator< _Tp, const _Tp &, const _Tp * > | const_iterator
typedef const value_type * | const_pointer
typedef const value_type & | const_reference
typedef std::ptrdiff_t | difference_type
typedef _Slist_iterator< _Tp, _Tp &, _Tp * > | iterator
typedef value_type * | pointer
typedef value_type & | reference
typedef std::size_t | size_type
typedef _Tp | value_type

## Public Member Functions

template<class _InputIterator>
| slist (_InputIterator __first, _InputIterator __last, const allocator_type &__a=allocator_type())
| slist (const allocator_type &__a=allocator_type())
| slist (const slist &__x)
| slist (size_type __n)
| slist (size_type __n, const value_type &__x, const allocator_type &__a=allocator_type())
template<class _InputIterator>
void | _M_assign_dispatch (_InputIterator __first, _InputIterator __last, std::__false_type)
template<class _Integer>
void | _M_assign_dispatch (_Integer __n, _Integer __val, std::__true_type)
void | _M_fill_assign (size_type __n, const _Tp &__val)
template<class _InputIterator>
void | assign (_InputIterator __first, _InputIterator __last)
void | assign (size_type __n, const _Tp &__val)
iterator | before_begin ()
const_iterator | before_begin () const
iterator | begin ()
const_iterator | begin () const
void | clear ()
bool | empty () const
iterator | end ()
const_iterator | end () const
iterator | erase (iterator __first, iterator __last)
iterator | erase (iterator __pos)
iterator | erase_after (iterator __before_first, iterator __last)
iterator | erase_after (iterator __pos)
reference | front ()
const_reference | front () const
allocator_type | get_allocator () const
iterator | insert (iterator __pos)
template<class _InIterator>
void | insert (iterator __pos, _InIterator __first, _InIterator __last)
iterator | insert (iterator __pos, const value_type &__x)
void | insert (iterator __pos, size_type __n, const value_type &__x)
iterator | insert_after (iterator __pos)
template<class _InIterator>
void | insert_after (iterator __pos, _InIterator __first, _InIterator __last)
iterator | insert_after (iterator __pos, const value_type &__x)
void | insert_after (iterator __pos, size_type __n, const value_type &__x)
size_type | max_size () const
template<class _StrictWeakOrdering>
void | merge (slist &, _StrictWeakOrdering)
void | merge (slist &__x)
slist & | operator= (const slist &__x)
void | pop_front ()
iterator | previous (const_iterator __pos)
const_iterator | previous (const_iterator __pos) const
void | push_front ()
void | push_front (const value_type &__x)
void | remove (const _Tp &__val)
template<class _Predicate>
void | remove_if (_Predicate __pred)
void | resize (size_type new_size)
void | resize (size_type new_size, const _Tp &__x)
void | reverse ()
size_type | size () const
void | sort ()
template<class _StrictWeakOrdering>
void | sort (_StrictWeakOrdering __comp)
void | splice (iterator __pos, slist &__x)
void | splice (iterator __pos, slist &__x, iterator __first, iterator __last)
void | splice (iterator __pos, slist &__x, iterator __i)
void | splice_after (iterator __pos, iterator __before_first, iterator __before_last)
void | splice_after (iterator __pos, iterator __prev)
void | splice_after (iterator __pos, slist &__x)
void | swap (slist &__x)
void | unique ()
template<class _BinaryPredicate>
void | unique (_BinaryPredicate __pred)

## Static Private Member Functions

static constexpr size_type | max_size (const _Alloc &__a) noexcept

## Detailed Description

template<class _Tp, class _Alloc = std::allocator<_Tp>>
class __gnu_cxx::slist< _Tp, _Alloc >

This is an SGI extension.

Todo
  Needs documentation! See http://gcc.gnu.org/onlinedocs/libstdc++/manual/documentation_style.html

Definition at line 289 of file slist.

## Member Typedef Documentation

## allocator_type

template<class _Tp, class _Alloc = std::allocator<_Tp>>

typedef _Base::allocator_type __gnu_cxx::slist< _Tp, _Alloc >::allocator_type

Definition at line 309 of file slist.

## const_iterator

template<class _Tp, class _Alloc = std::allocator<_Tp>>

typedef _Slist_iterator<_Tp, const _Tp&, const _Tp*> __gnu_cxx::slist< _Tp, _Alloc >::const_iterator

Definition at line 307 of file slist.

## const_pointer

template<class _Tp, class _Alloc = std::allocator<_Tp>>

typedef const value_type* __gnu_cxx::slist< _Tp, _Alloc >::const_pointer

Definition at line 300 of file slist.

## const_reference

template<class _Tp, class _Alloc = std::allocator<_Tp>>

typedef const value_type& __gnu_cxx::slist< _Tp, _Alloc >::const_reference

Definition at line 302 of file slist.

## difference_type

template<class _Tp, class _Alloc = std::allocator<_Tp>>

typedef std::ptrdiff_t __gnu_cxx::slist< _Tp, _Alloc >::difference_type

Definition at line 304 of file slist.

## iterator

template<class _Tp, class _Alloc = std::allocator<_Tp>>

typedef _Slist_iterator<_Tp, _Tp&, _Tp*> __gnu_cxx::slist< _Tp, _Alloc >::iterator

Definition at line 306 of file slist.

## pointer

template<class _Tp, class _Alloc = std::allocator<_Tp>>

typedef value_type* __gnu_cxx::slist< _Tp, _Alloc >::pointer

Definition at line 299 of file slist.

## reference

template<class _Tp, class _Alloc = std::allocator<_Tp>>

typedef value_type& __gnu_cxx::slist< _Tp, _Alloc >::reference

Definition at line 301 of file slist.

## size_type

template<class _Tp, class _Alloc = std::allocator<_Tp>>

typedef std::size_t __gnu_cxx::slist< _Tp, _Alloc >::size_type

Definition at line 303 of file slist.

## value_type

template<class _Tp, class _Alloc = std::allocator<_Tp>>

typedef _Tp __gnu_cxx::slist< _Tp, _Alloc >::value_type

Definition at line 298 of file slist.

## Constructor & Destructor Documentation

## slist() [1/5]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

__gnu_cxx::slist< _Tp, _Alloc >::slist | ( | const allocator_type & | __a = allocator_type() | ) |

inline explicit

Definition at line 360 of file slist.

## slist() [2/5]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

__gnu_cxx::slist< _Tp, _Alloc >::slist | ( | size_type | __n,
|  | const value_type & | __x,
|  | const allocator_type & | __a = allocator_type() )

inline

Definition at line 363 of file slist.

## slist() [3/5]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

__gnu_cxx::slist< _Tp, _Alloc >::slist | ( | size_type | __n | ) |

inline explicit

Definition at line 369 of file slist.

## slist() [4/5]

template<class _Tp, class _Alloc = std::allocator<_Tp>>
template<class _InputIterator>

__gnu_cxx::slist< _Tp, _Alloc >::slist | ( | _InputIterator | __first,
|  | _InputIterator | __last,
|  | const allocator_type & | __a = allocator_type() )

inline

Definition at line 376 of file slist.

## slist() [5/5]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

__gnu_cxx::slist< _Tp, _Alloc >::slist | ( | const slist< _Tp, _Alloc > & | __x | ) |

inline

Definition at line 381 of file slist.

## ~slist()

template<class _Tp, class _Alloc = std::allocator<_Tp>>

__gnu_cxx::slist< _Tp, _Alloc >::~slist | ( |  | ) |

inline

Definition at line 388 of file slist.

## Member Function Documentation

## _M_assign_dispatch() [1/2]

template<class _Tp, class _Alloc>
template<class _InputIterator>

void __gnu_cxx::slist< _Tp, _Alloc >::_M_assign_dispatch | ( | _InputIterator | __first,
|  | _InputIterator | __last,
|  | std::__false_type | )

Definition at line 774 of file slist.

## _M_assign_dispatch() [2/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>
template<class _Integer>

void __gnu_cxx::slist< _Tp, _Alloc >::_M_assign_dispatch | ( | _Integer | __n,
|  | _Integer | __val,
|  | std::__true_type | )

inline

Definition at line 413 of file slist.

## _M_fill_assign()

template<class _Tp, class _Alloc>

void __gnu_cxx::slist< _Tp, _Alloc >::_M_fill_assign | ( | size_type | __n,
|  | const _Tp & | __val )

Definition at line 755 of file slist.

## assign() [1/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>
template<class _InputIterator>

void __gnu_cxx::slist< _Tp, _Alloc >::assign | ( | _InputIterator | __first,
|  | _InputIterator | __last )

inline

Definition at line 405 of file slist.

## assign() [2/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

void __gnu_cxx::slist< _Tp, _Alloc >::assign | ( | size_type | __n,
|  | const _Tp & | __val )

inline

Definition at line 397 of file slist.

## before_begin() [1/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

iterator __gnu_cxx::slist< _Tp, _Alloc >::before_begin | ( |  | ) |

inline

Definition at line 447 of file slist.

## before_begin() [2/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

const_iterator __gnu_cxx::slist< _Tp, _Alloc >::before_begin | ( |  | ) | const

inline

Definition at line 451 of file slist.

## begin() [1/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

iterator __gnu_cxx::slist< _Tp, _Alloc >::begin | ( |  | ) |

inline

Definition at line 424 of file slist.

## begin() [2/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

const_iterator __gnu_cxx::slist< _Tp, _Alloc >::begin | ( |  | ) | const

inline

Definition at line 428 of file slist.

## clear()

template<class _Tp, class _Alloc = std::allocator<_Tp>>

void __gnu_cxx::slist< _Tp, _Alloc >::clear | ( |  | ) |

inline

Definition at line 634 of file slist.

## empty()

template<class _Tp, class _Alloc = std::allocator<_Tp>>

bool __gnu_cxx::slist< _Tp, _Alloc >::empty | ( |  | ) | const

inline nodiscard

Definition at line 463 of file slist.

## end() [1/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

iterator __gnu_cxx::slist< _Tp, _Alloc >::end | ( |  | ) |

inline

Definition at line 432 of file slist.

## end() [2/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

const_iterator __gnu_cxx::slist< _Tp, _Alloc >::end | ( |  | ) | const

inline

Definition at line 436 of file slist.

## erase() [1/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

iterator __gnu_cxx::slist< _Tp, _Alloc >::erase | ( | iterator | __first,
|  | iterator | __last )

inline

Definition at line 619 of file slist.

## erase() [2/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

iterator __gnu_cxx::slist< _Tp, _Alloc >::erase | ( | iterator | __pos | ) |

inline

Definition at line 612 of file slist.

## erase_after() [1/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

iterator __gnu_cxx::slist< _Tp, _Alloc >::erase_after | ( | iterator | __before_first,
|  | iterator | __last )

inline

Definition at line 605 of file slist.

## erase_after() [2/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

iterator __gnu_cxx::slist< _Tp, _Alloc >::erase_after | ( | iterator | __pos | ) |

inline

Definition at line 601 of file slist.

## front() [1/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

reference __gnu_cxx::slist< _Tp, _Alloc >::front | ( |  | ) |

inline

Definition at line 473 of file slist.

## front() [2/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

const_reference __gnu_cxx::slist< _Tp, _Alloc >::front | ( |  | ) | const

inline

Definition at line 477 of file slist.

## get_allocator()

template<class _Tp, class _Alloc = std::allocator<_Tp>>

allocator_type __gnu_cxx::slist< _Tp, _Alloc >::get_allocator | ( |  | ) | const

inline

Definition at line 312 of file slist.

## insert() [1/4]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

iterator __gnu_cxx::slist< _Tp, _Alloc >::insert | ( | iterator | __pos | ) |

inline

Definition at line 581 of file slist.

## insert() [2/4]

template<class _Tp, class _Alloc = std::allocator<_Tp>>
template<class _InIterator>

void __gnu_cxx::slist< _Tp, _Alloc >::insert | ( | iterator | __pos,
|  | _InIterator | __first,
|  | _InIterator | __last )

inline

Definition at line 595 of file slist.

## insert() [3/4]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

iterator __gnu_cxx::slist< _Tp, _Alloc >::insert | ( | iterator | __pos,
|  | const value_type & | __x )

inline

Definition at line 575 of file slist.

## insert() [4/4]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

void __gnu_cxx::slist< _Tp, _Alloc >::insert | ( | iterator | __pos,
|  | size_type | __n,
|  | const value_type & | __x )

inline

Definition at line 587 of file slist.

## insert_after() [1/4]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

iterator __gnu_cxx::slist< _Tp, _Alloc >::insert_after | ( | iterator | __pos | ) |

inline

Definition at line 560 of file slist.

## insert_after() [2/4]

template<class _Tp, class _Alloc = std::allocator<_Tp>>
template<class _InIterator>

void __gnu_cxx::slist< _Tp, _Alloc >::insert_after | ( | iterator | __pos,
|  | _InIterator | __first,
|  | _InIterator | __last )

inline

Definition at line 571 of file slist.

## insert_after() [3/4]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

iterator __gnu_cxx::slist< _Tp, _Alloc >::insert_after | ( | iterator | __pos,
|  | const value_type & | __x )

inline

Definition at line 556 of file slist.

## insert_after() [4/4]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

void __gnu_cxx::slist< _Tp, _Alloc >::insert_after | ( | iterator | __pos,
|  | size_type | __n,
|  | const value_type & | __x )

inline

Definition at line 564 of file slist.

## max_size()

template<class _Tp, class _Alloc = std::allocator<_Tp>>

size_type __gnu_cxx::slist< _Tp, _Alloc >::max_size | ( |  | ) | const

inline

Definition at line 459 of file slist.

## merge() [1/2]

template<class _Tp, class _Alloc>
template<class _StrictWeakOrdering>

void __gnu_cxx::slist< _Tp, _Alloc >::merge | ( | slist< _Tp, _Alloc > & | __x,
|  | _StrictWeakOrdering | __comp )

Definition at line 977 of file slist.

## merge() [2/2]

template<class _Tp, class _Alloc>

void __gnu_cxx::slist< _Tp, _Alloc >::merge | ( | slist< _Tp, _Alloc > & | __x | ) |

Definition at line 893 of file slist.

## operator=()

template<class _Tp, class _Alloc>

slist< _Tp, _Alloc > & __gnu_cxx::slist< _Tp, _Alloc >::operator= | ( | const slist< _Tp, _Alloc > & | __x | ) |

Definition at line 730 of file slist.

## pop_front()

template<class _Tp, class _Alloc = std::allocator<_Tp>>

void __gnu_cxx::slist< _Tp, _Alloc >::pop_front | ( |  | ) |

inline

Definition at line 489 of file slist.

## previous() [1/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

iterator __gnu_cxx::slist< _Tp, _Alloc >::previous | ( | const_iterator | __pos | ) |

inline

Definition at line 499 of file slist.

## previous() [2/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

const_iterator __gnu_cxx::slist< _Tp, _Alloc >::previous | ( | const_iterator | __pos | ) | const

inline

Definition at line 504 of file slist.

## push_front() [1/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

void __gnu_cxx::slist< _Tp, _Alloc >::push_front | ( |  | ) |

inline

Definition at line 485 of file slist.

## push_front() [2/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

void __gnu_cxx::slist< _Tp, _Alloc >::push_front | ( | const value_type & | __x | ) |

inline

Definition at line 481 of file slist.

## remove()

template<class _Tp, class _Alloc>

void __gnu_cxx::slist< _Tp, _Alloc >::remove | ( | const _Tp & | __val | ) |

Definition at line 861 of file slist.

## remove_if()

template<class _Tp, class _Alloc>
template<class _Predicate>

void __gnu_cxx::slist< _Tp, _Alloc >::remove_if | ( | _Predicate | __pred | ) |

Definition at line 943 of file slist.

## resize() [1/2]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

void __gnu_cxx::slist< _Tp, _Alloc >::resize | ( | size_type | new_size | ) |

inline

Definition at line 630 of file slist.

## resize() [2/2]

template<class _Tp, class _Alloc>

void __gnu_cxx::slist< _Tp, _Alloc >::resize | ( | size_type | new_size,
|  | const _Tp & | __x )

Definition at line 845 of file slist.

## reverse()

template<class _Tp, class _Alloc = std::allocator<_Tp>>

void __gnu_cxx::slist< _Tp, _Alloc >::reverse | ( |  | ) |

inline

Definition at line 693 of file slist.

## size()

template<class _Tp, class _Alloc = std::allocator<_Tp>>

size_type __gnu_cxx::slist< _Tp, _Alloc >::size | ( |  | ) | const

inline

Definition at line 455 of file slist.

## sort() [1/2]

template<class _Tp, class _Alloc>

void __gnu_cxx::slist< _Tp, _Alloc >::sort | ( |  | ) |

Definition at line 912 of file slist.

## sort() [2/2]

template<class _Tp, class _Alloc>
template<class _StrictWeakOrdering>

void __gnu_cxx::slist< _Tp, _Alloc >::sort | ( | _StrictWeakOrdering | __comp | ) |

Definition at line 998 of file slist.

## splice() [1/3]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

void __gnu_cxx::slist< _Tp, _Alloc >::splice | ( | iterator | __pos,
|  | slist< _Tp, _Alloc > & | __x )

inline

Definition at line 665 of file slist.

## splice() [2/3]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

void __gnu_cxx::slist< _Tp, _Alloc >::splice | ( | iterator | __pos,
|  | slist< _Tp, _Alloc > & | __x,
|  | iterator | __first,
|  | iterator | __last )

inline

Definition at line 682 of file slist.

## splice() [3/3]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

void __gnu_cxx::slist< _Tp, _Alloc >::splice | ( | iterator | __pos,
|  | slist< _Tp, _Alloc > & | __x,
|  | iterator | __i )

inline

Definition at line 674 of file slist.

## splice_after() [1/3]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

void __gnu_cxx::slist< _Tp, _Alloc >::splice_after | ( | iterator | __pos,
|  | iterator | __before_first,
|  | iterator | __before_last )

inline

Definition at line 641 of file slist.

## splice_after() [2/3]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

void __gnu_cxx::slist< _Tp, _Alloc >::splice_after | ( | iterator | __pos,
|  | iterator | __prev )

inline

Definition at line 652 of file slist.

## splice_after() [3/3]

template<class _Tp, class _Alloc = std::allocator<_Tp>>

void __gnu_cxx::slist< _Tp, _Alloc >::splice_after | ( | iterator | __pos,
|  | slist< _Tp, _Alloc > & | __x )

inline

Definition at line 660 of file slist.

## swap()

template<class _Tp, class _Alloc = std::allocator<_Tp>>

void __gnu_cxx::slist< _Tp, _Alloc >::swap | ( | slist< _Tp, _Alloc > & | __x | ) |

inline

Definition at line 467 of file slist.

## unique() [1/2]

template<class _Tp, class _Alloc>

void __gnu_cxx::slist< _Tp, _Alloc >::unique | ( |  | ) |

Definition at line 875 of file slist.

## unique() [2/2]

template<class _Tp, class _Alloc>
template<class _BinaryPredicate>

void __gnu_cxx::slist< _Tp, _Alloc >::unique | ( | _BinaryPredicate | __pred | ) |

Definition at line 958 of file slist.

The documentation for this class was generated from the following file:

- slist