Click
Loading...
Searching...
No Matches
Public Member Functions | List of all members
List_member< T > Class Template Reference

Member of classes to be placed on a List. More...

#include <list.hh>

Public Member Functions

 List_member ()
 Construct an isolated List_member.
 
T * next ()
 Return the next element in the list.
 
const T * next () const
 
T * prev ()
 Return the previous element in the list.
 
const T * prev () const
 

Detailed Description

template<typename T>
class List_member< T >

Member of classes to be placed on a List.

Any class type that will be placed on a List must have a publicly accessible List_member member. This member is supplied as the second template argument to List. List_member allows users to fetch the next-element and previous-element pointers, but all modifications must take place via List functions like List::push_back() and List::insert(). List_member has private copy constructor and default assignment operators.

See also
List

Constructor & Destructor Documentation

◆ List_member()

template<typename T >
List_member< T >::List_member ( )
inline

Construct an isolated List_member.

Member Function Documentation

◆ next() [1/2]

template<typename T >
T * List_member< T >::next ( )
inline

Return the next element in the list.

◆ next() [2/2]

template<typename T >
const T * List_member< T >::next ( ) const
inline

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

◆ prev() [1/2]

template<typename T >
T * List_member< T >::prev ( )
inline

Return the previous element in the list.

◆ prev() [2/2]

template<typename T >
const T * List_member< T >::prev ( ) const
inline

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.


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