L4Re Operating System Framework
Interface and Usage Documentation
Loading...
Searching...
No Matches
cxx::S_list< T, POLICY > Class Template Reference

Simple single-linked list. More...

#include <slist>

+ Inheritance diagram for cxx::S_list< T, POLICY >:
+ Collaboration diagram for cxx::S_list< T, POLICY >:

Public Member Functions

void add (T *e)
 Add an element to the front of the list.
 
void push_front (T *e)
 Add an element to the front of the list.
 
T * pop_front ()
 Remove and return the head element of the list.
 
- Public Member Functions inherited from cxx::Bits::Basic_list< POLICY >
bool empty () const
 Check if the list is empty.
 
Value_type front () const
 Return the first element in the list.
 
void clear ()
 Remove all elements from the list.
 
Iterator begin ()
 Return an iterator to the beginning of the list.
 
Const_iterator begin () const
 Return a const iterator to the beginning of the list.
 
Const_iterator end () const
 Return a const iterator to the end of the list.
 
Iterator end ()
 Return an iterator to the end of the list.
 

Additional Inherited Members

- Static Public Member Functions inherited from cxx::Bits::Basic_list< POLICY >
static Const_iterator iter (Const_value_type c)
 Return a const iterator that begins at the given element.
 
- Protected Attributes inherited from cxx::Bits::Basic_list< POLICY >
POLICY::Head_type _f
 Pointer to front of the list.
 

Detailed Description

template<typename T, typename POLICY = Bits::Basic_list_policy< T, S_list_item >>
class cxx::S_list< T, POLICY >

Simple single-linked list.

Template Parameters
TType of elements saved in the list. Must inherit from cxx::S_list_item

Definition at line 51 of file slist.

Member Function Documentation

◆ pop_front()

template<typename T , typename POLICY = Bits::Basic_list_policy< T, S_list_item >>
T * cxx::S_list< T, POLICY >::pop_front ( )
inline

Remove and return the head element of the list.

Precondition
The list must not be empty or the behaviour will be undefined.

Definition at line 100 of file slist.

References cxx::Bits::Basic_list< POLICY >::_f, and cxx::Bits::Basic_list< POLICY >::front().

+ Here is the call graph for this function:

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