torcs - 1.2.0

Main Page   Modules   Compound List   File List   Compound Members   File Members   Related Pages  

torcs/src/libs/tgf/ringlist.cpp File Reference


Detailed Description

Ring list management.

The ring lists are linked lists without end, the tail is linked to the head. The list pointer is on the tail, so the access to the head is list->next. The first two fields of the elements are always next and prev.

Author:
Eric Espie
Version:

#include <tgf.h>

Include dependency graph for ringlist.cpp:

Include dependency graph

Functions

void GfRlstInit (tRingListHead *head)
 Initialize the ring list head.

void GfRlstAddFirst (tRingListHead *head, tRingList *elt)
 Add an element in first position of a double link ring list.

void GfRlstAddLast (tRingListHead *head, tRingList *elt)
 Add an element in last position of a double link ring list.

tRingListGfRlstUnlinkFirst (tRingListHead *head)
 Unlink the first element of a ring list.

tRingListGfRlstUnlinkLast (tRingListHead *head)
 Unlink the last element of a ring list.

tRingListGfRlstUnlinkElt (tRingList *elt)
 Unlink an element of a double link ring list.

tRingListGfRlstGetFirst (tRingListHead *head)
 Get the first element of a ring list without unlinking it.

tRingListGfRlstGetLast (tRingListHead *head)
 Get the last element of a ring list without unlinking it.

tRingListGfRlstGetNext (tRingListHead *head, tRingList *elt)
 Get the next element of a ring list without unlinking it.

tRingListGfRlstGetPrev (tRingListHead *head, tRingList *elt)
 Get the previous element of a ring list without unlinking it.

void GfRlstSeekElt (tRingListHead *head, tRingList *elt)
 Set the head before the specified element.


Generated at Fri Apr 4 00:29:57 2003 for torcs by doxygen 1.3-rc1 written by Dimitri van Heesch, © 1997-1999
TORCS © Eric Espié 1999, 2002.