SoPlex
Loading...
Searching...
No Matches
IdElement< T > Class Template Reference

Elements for IdLists. More...

#include <idlist.h>

Inheritance diagram for IdElement< T >:

Public Member Functions

Successors and predecessors
IdElement< T > *& next ()
 returns the next element in the IdList (writeable).
 
IdElement< T > *const & next () const
 returns the next element in the IdList.
 
IdElement< T > *& prev ()
 returns the previous element in the IdList (writeable).
 
IdElement< T > *const & prev () const
 returns the previous element in the IdList.
 
Construction / destruction
 IdElement ()
 default constructor.
 
 IdElement (const T &old)
 copy constructor.
 

Private Attributes

Data
IdElement< T > * theprev
 pointer to previous element in the IdList
 
IdElement< T > * thenext
 pointer to next element in the IdList
 

Detailed Description

template<class T>
class soplex::IdElement< T >

Elements for IdLists.

IdElements are derived from the template parameter class T and can hence be used as such. The additional methods next() and prev() provide access to the links for the list. They may freely be used by the programmer as long as an IdElement is not member of a IdList. In this case, the IdList controls members next() and prev(). However, IdList should provide enough functionality for the user not to require any modification to these members.

Definition at line 61 of file idlist.h.

Constructor & Destructor Documentation

◆ IdElement() [1/2]

template<class T>
IdElement ( )

default constructor.

Definition at line 102 of file idlist.h.

References thenext, and theprev.

Referenced by next(), next(), prev(), and prev().

◆ IdElement() [2/2]

template<class T>
IdElement ( const T & old)

copy constructor.

Only the element itself is copied, while the links to the previous and the next list element are set to zero pointers.

Definition at line 111 of file idlist.h.

References thenext, and theprev.

Member Function Documentation

◆ next() [1/2]

template<class T>
IdElement< T > *& next ( )

returns the next element in the IdList (writeable).

Definition at line 76 of file idlist.h.

References IdElement(), and thenext.

◆ next() [2/2]

template<class T>
IdElement< T > *const & next ( ) const

returns the next element in the IdList.

Definition at line 81 of file idlist.h.

References IdElement(), and thenext.

◆ prev() [1/2]

template<class T>
IdElement< T > *& prev ( )

returns the previous element in the IdList (writeable).

Definition at line 87 of file idlist.h.

References IdElement(), and theprev.

◆ prev() [2/2]

template<class T>
IdElement< T > *const & prev ( ) const

returns the previous element in the IdList.

Definition at line 92 of file idlist.h.

References IdElement(), and theprev.

Member Data Documentation

◆ thenext

template<class T>
IdElement<T>* thenext
private

pointer to next element in the IdList

Definition at line 67 of file idlist.h.

Referenced by IdElement(), IdElement(), next(), and next().

◆ theprev

template<class T>
IdElement<T>* theprev
private

pointer to previous element in the IdList

Definition at line 66 of file idlist.h.

Referenced by IdElement(), IdElement(), prev(), and prev().