AI_List Class Reference
[Utilities]
#include <AI_List.h>
Detailed Description
Implement a doubly linked list.
- Version:
- 2.0 nList was ripped from The Nebula Device and renamed to AI_List. Now it is possible to use the class inside and outside Nebula projects.
| Public Member Functions | |
| AI_List () | |
| constructor | |
| ~AI_List () | |
| destructor (list must be empty!) | |
| bool | IsEmpty () const | 
| checks if list is empty | |
| AI_Node * | GetHead () const | 
| returns first node in list, 0 if empty | |
| AI_Node * | GetTail () const | 
| returns last node in list, 0 if empty | |
| void | AddHead (AI_Node *n) | 
| add node to head of list | |
| void | AddTail (AI_Node *n) | 
| add node to end of list | |
| AI_Node * | RemHead () | 
| remove node from head of list | |
| AI_Node * | RemTail () | 
| remove node from tail of list | |
Constructor & Destructor Documentation
| AI_List::AI_List | ( | ) |  [inline] | 
constructor
| AI_List::~AI_List | ( | ) |  [inline] | 
destructor (list must be empty!)
Destroy list object. The list has to be empty, otherwise an assertion will be thrown.
Member Function Documentation
| bool AI_List::IsEmpty | ( | ) | const  [inline] | 
checks if list is empty
- Returns:
- true if list is empty.
| AI_Node * AI_List::GetHead | ( | ) | const  [inline] | 
returns first node in list, 0 if empty
- Returns:
- return first node in list, or 0 if list is empty
| AI_Node * AI_List::GetTail | ( | ) | const  [inline] | 
returns last node in list, 0 if empty
- Returns:
- return last node in list, or 0 if list is empty
| void AI_List::AddHead | ( | AI_Node * | n | ) |  [inline] | 
add node to head of list
- Parameters:
- 
  n the node to be added 
| void AI_List::AddTail | ( | AI_Node * | n | ) |  [inline] | 
add node to end of list
- Parameters:
- 
  n the node to be added 
| AI_Node * AI_List::RemHead | ( | ) |  [inline] | 
remove node from head of list
Remove node at head of list, and return pointer to it. Returns 0 if list is empty.
- Returns:
- the removed node or 0 if list is empty
| AI_Node * AI_List::RemTail | ( | ) |  [inline] | 
remove node from tail of list
Remove node at tail of list, and return pointer to it. Returns 0 if list is empty.
- Returns:
- the removed node or 0 if list is empty
The documentation for this class was generated from the following file:
