PUMA Library Reference Manual
Loading...
Searching...
No Matches
Puma::Chain Class Reference

#include <Puma/Chain.h>

+ Inheritance diagram for Puma::Chain:

Description

Simple single-linked chain implementation.

A chain consists of elements each linked to its direct follower element.

Public Member Functions

 Chain ()
 Construct a single chain element. More...
 
void select (Chain *element)
 Select an element as the next element. More...
 
Chainselect () const
 Get the next element. More...
 
Chainunlink ()
 Unlink the next element from the chain. More...
 
void insert (Chain *element)
 Insert an element in the chain as the next element. More...
 

Constructor & Destructor Documentation

◆ Chain()

Puma::Chain::Chain ( )
inline

Construct a single chain element.

Member Function Documentation

◆ insert()

void Puma::Chain::insert ( Chain element)
inline

Insert an element in the chain as the next element.

Parameters
elementThe element to insert.

◆ select() [1/2]

Chain * Puma::Chain::select ( ) const
inline

Get the next element.

Returns
A pointer to the next chain element.

◆ select() [2/2]

void Puma::Chain::select ( Chain element)
inline

Select an element as the next element.

Parameters
elementThe next element.

◆ unlink()

Chain * Puma::Chain::unlink ( )
inline

Unlink the next element from the chain.

Returns
The unlinked next element.