Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
QLNode Class Reference

The QLNode class is an internal class for the QList template collection. More...

#include <qglist.h>

Public Member Functions

QCollection::Item getData ()
 

Private Member Functions

 QLNode (QCollection::Item d)
 

Private Attributes

QCollection::Item data
 
QLNodeprev
 
QLNodenext
 

Friends

class QGList
 
class QGListIterator
 

Detailed Description

The QLNode class is an internal class for the QList template collection.

QLNode is a doubly linked list node; it has three pointers:

  1. Pointer to the previous node.
  2. Pointer to the next node.
  3. Pointer to the actual data.

Sometimes it might be practical to have direct access to the list nodes in a QList, but it is seldom required.

Warning
Be very careful if you want to access the list nodes. The heap can easily get corrupted if you make a mistake.
See also
QList::currentNode(), QList::removeNode(), QList::takeNode()

Definition at line 50 of file qglist.h.

Constructor & Destructor Documentation

QLNode::QLNode ( QCollection::Item  d)
inlineprivate

Definition at line 60 of file qglist.h.

60 { data = d; }
QCollection::Item data
Definition: qglist.h:57

Member Function Documentation

QCollection::Item QLNode::getData ( )
inline

Returns a pointer (void*) to the actual data in the list node.

Definition at line 55 of file qglist.h.

55 { return data; }
QCollection::Item data
Definition: qglist.h:57

Friends And Related Function Documentation

friend class QGList
friend

Definition at line 52 of file qglist.h.

friend class QGListIterator
friend

Definition at line 53 of file qglist.h.

Member Data Documentation

QCollection::Item QLNode::data
private

Definition at line 57 of file qglist.h.

QLNode* QLNode::next
private

Definition at line 59 of file qglist.h.

QLNode* QLNode::prev
private

Definition at line 58 of file qglist.h.


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