Richard Boegli's CnC_Generals_Zero_Hour Fork WIP
This is documentation of Richard Boegil's Zero Hour Fork
 
Loading...
Searching...
No Matches
LListNode Class Reference

#include <List.h>

Public Member Functions

 LListNode ()
 Constructor.
 
void remove (void)
 Removes node from list.
 
void insert (LListNode *new_node)
 Inserts new_node infront of itself.
 
void append (LListNode *new_node)
 Appends new node after itself.
 
LListNodenext (void)
 Returns next node in list.
 
LListNodeprev (void)
 Returns previous node in list.
 
LListNodeloopNext (void)
 Returns next node in list, warpping round to start of list if nessecary.
 
LListNodeloopPrev (void)
 Returns previous node in list, wrapping round to end of list if nessecary.
 
Bool inList (void)
 Returns whether or not node in list.
 
Bool isHead (void)
 Returns whether or not this node is the head/tail node.
 
Int priority (void)
 Returns node's priority.
 
void setPriority (Int new_pri)
 Sets node's priority.
 
void * item (void)
 Returns the item this links to, if any.
 
void setItem (void *item)
 Make node point to an item.
 
void destroy (void)
 Delete node.
 
void autoDelete (void)
 

Protected Attributes

LListNodem_next
 Next node in list.
 
LListNodem_prev
 Previous node in list.
 
Int m_pri
 Node's priority, used for sorting.
 
void * m_item
 Item we are referencing if any.
 
Bool m_autoDelete
 destroy() should call delete
 

Friends

class LList
 

Detailed Description

Link list node abstraction for WSYS.

Definition at line 75 of file List.h.

Constructor & Destructor Documentation

◆ LListNode()

LListNode::LListNode ( )

Constructor.

Definition at line 314 of file List.cpp.

Member Function Documentation

◆ append()

void LListNode::append ( LListNode * new_node)

Appends new node after itself.

Definition at line 338 of file List.cpp.

◆ autoDelete()

void LListNode::autoDelete ( void )
inline

Definition at line 168 of file List.h.

◆ destroy()

void LListNode::destroy ( void )

Delete node.

Definition at line 436 of file List.cpp.

◆ inList()

Bool LListNode::inList ( void )
inline

Returns whether or not node in list.

Definition at line 164 of file List.h.

◆ insert()

void LListNode::insert ( LListNode * new_node)

Inserts new_node infront of itself.

Definition at line 326 of file List.cpp.

◆ isHead()

Bool LListNode::isHead ( void )
inline

Returns whether or not this node is the head/tail node.

Definition at line 165 of file List.h.

◆ item()

void * LListNode::item ( void )
inline

Returns the item this links to, if any.

Definition at line 169 of file List.h.

◆ loopNext()

LListNode * LListNode::loopNext ( void )

Returns next node in list, warpping round to start of list if nessecary.

Definition at line 390 of file List.cpp.

◆ loopPrev()

LListNode * LListNode::loopPrev ( void )

Returns previous node in list, wrapping round to end of list if nessecary.

Definition at line 413 of file List.cpp.

◆ next()

LListNode * LListNode::next ( void )

Returns next node in list.

Definition at line 361 of file List.cpp.

◆ prev()

LListNode * LListNode::prev ( void )

Returns previous node in list.

Definition at line 376 of file List.cpp.

◆ priority()

Int LListNode::priority ( void )
inline

Returns node's priority.

Definition at line 166 of file List.h.

◆ remove()

void LListNode::remove ( void )

Removes node from list.

Definition at line 350 of file List.cpp.

◆ setItem()

void LListNode::setItem ( void * item)
inline

Make node point to an item.

Definition at line 170 of file List.h.

◆ setPriority()

void LListNode::setPriority ( Int new_pri)
inline

Sets node's priority.

Definition at line 167 of file List.h.

Friends And Related Symbol Documentation

◆ LList

friend class LList
friend

Definition at line 77 of file List.h.

Member Data Documentation

◆ m_autoDelete

Bool LListNode::m_autoDelete
protected

destroy() should call delete

Definition at line 85 of file List.h.

◆ m_item

void* LListNode::m_item
protected

Item we are referencing if any.

Definition at line 84 of file List.h.

◆ m_next

LListNode* LListNode::m_next
protected

Next node in list.

Definition at line 81 of file List.h.

◆ m_prev

LListNode* LListNode::m_prev
protected

Previous node in list.

Definition at line 82 of file List.h.

◆ m_pri

Int LListNode::m_pri
protected

Node's priority, used for sorting.

Definition at line 83 of file List.h.


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