#include <ALStructure.h>
Public Member Functions | |
ALStructure () | |
~ALStructure () | |
ALElement * | getRaHead () |
ALElement * | getDecHead () |
ALElement * | getTail () |
void | remove (ALElement *element) |
void | add (ActiveObject *activeObject) |
ALElement * | findLeastGE (double ra) |
ALElement * | findLeastG (double ra) |
unsigned int | getSize () |
Private Types | |
enum | Child { left, right } |
Private Member Functions | |
ALStructure (ALStructure const &) | |
ALStructure & | operator= (ALStructure const &) |
void | findNode (ALElement *element, ALNode *root, ALNode **parent, Child *child) |
ALNode * | grabSuccessor (ALNode *node) |
void | removeNode (ALElement *element) |
ALElement * | insertNew (ActiveObject *object, ALElement *nextRa, ALElement *nextDec) |
ALElement * | findLowerBound (double ra, bool allowEquality) |
Private Attributes | |
unsigned int | size |
ALElement | sentinel |
ALElement * | raHead |
ALElement * | decHead |
ALElement * | tail |
ALNode * | rootNode |
Definition at line 28 of file ALStructure.h.
enum ALStructure::Child [private] |
Definition at line 65 of file ALStructure.h.
ALStructure::ALStructure | ( | ) |
Definition at line 41 of file ALStructure.cpp.
ALStructure::~ALStructure | ( | ) |
Definition at line 52 of file ALStructure.cpp.
References rootNode.
ALStructure::ALStructure | ( | ALStructure const & | ) | [private] |
void ALStructure::add | ( | ActiveObject * | activeObject | ) |
Definition at line 391 of file ALStructure.cpp.
References ALElement::getContent(), ALNode::getElement(), ALNode::getLeftChild(), ALElement::getNextRa(), ALNode::getRightChild(), insertNew(), rootNode, ALNode::setLeftChild(), ALNode::setRightChild(), and tail.
Referenced by IndexedActiveList::pushBack().
ALElement * ALStructure::findLeastG | ( | double | ra | ) |
Definition at line 66 of file ALStructure.cpp.
References findLowerBound().
ALElement * ALStructure::findLeastGE | ( | double | ra | ) |
Definition at line 59 of file ALStructure.cpp.
References findLowerBound().
Referenced by IndexedActiveList::testObject().
ALElement * ALStructure::findLowerBound | ( | double | ra, | |
bool | allowEquality | |||
) | [private] |
Definition at line 75 of file ALStructure.cpp.
References ALElement::getContent(), ALNode::getElement(), ALNode::getLeftChild(), ActiveObject::getObject(), Object::getRa(), ALNode::getRightChild(), rootNode, and tail.
Referenced by findLeastG(), and findLeastGE().
void ALStructure::findNode | ( | ALElement * | element, | |
ALNode * | root, | |||
ALNode ** | parent, | |||
ALStructure::Child * | child | |||
) | [private] |
Definition at line 278 of file ALStructure.cpp.
References ALElement::getContent(), ALNode::getElement(), ALNode::getLeftChild(), ActiveObject::getObject(), Object::getRa(), ALNode::getRightChild(), left, and right.
Referenced by removeNode().
ALElement* ALStructure::getDecHead | ( | ) | [inline] |
Definition at line 35 of file ALStructure.h.
References decHead.
Referenced by IndexedActiveList::clear(), IndexedActiveList::deletePriorObjects(), IndexedActiveList::popFront(), and IndexedActiveList::remove().
ALElement* ALStructure::getRaHead | ( | ) | [inline] |
Definition at line 34 of file ALStructure.h.
References raHead.
Referenced by IndexedActiveList::testObject().
unsigned int ALStructure::getSize | ( | ) |
Definition at line 511 of file ALStructure.cpp.
References size.
Referenced by IndexedActiveList::isEmpty(), and IndexedActiveList::testObject().
ALElement* ALStructure::getTail | ( | ) | [inline] |
Definition at line 36 of file ALStructure.h.
References tail.
Referenced by IndexedActiveList::clear(), IndexedActiveList::deletePriorObjects(), and IndexedActiveList::testObject().
Definition at line 363 of file ALStructure.cpp.
References ALNode::getLeftChild(), ALNode::getRightChild(), ALNode::setLeftChild(), and ALNode::setRightChild().
Referenced by removeNode().
ALElement * ALStructure::insertNew | ( | ActiveObject * | object, | |
ALElement * | nextRa, | |||
ALElement * | nextDec | |||
) | [private] |
Definition at line 467 of file ALStructure.cpp.
References decHead, ALElement::getPrevDec(), ALElement::getPrevRa(), raHead, ALElement::setNextDec(), ALElement::setNextRa(), ALElement::setPrevDec(), ALElement::setPrevRa(), and size.
Referenced by add().
ALStructure& ALStructure::operator= | ( | ALStructure const & | ) | [private] |
void ALStructure::remove | ( | ALElement * | element | ) |
Definition at line 148 of file ALStructure.cpp.
References decHead, ALElement::getNextDec(), ALElement::getNextRa(), ALElement::getPrevDec(), ALElement::getPrevRa(), raHead, removeNode(), ALElement::setNextDec(), ALElement::setNextRa(), ALElement::setPrevDec(), ALElement::setPrevRa(), and size.
Referenced by IndexedActiveList::remove().
void ALStructure::removeNode | ( | ALElement * | element | ) | [private] |
Definition at line 184 of file ALStructure.cpp.
References findNode(), ALNode::getElement(), ALNode::getLeftChild(), ALNode::getRightChild(), grabSuccessor(), left, rootNode, ALNode::setLeftChild(), and ALNode::setRightChild().
Referenced by remove().
ALElement* ALStructure::decHead [private] |
Definition at line 60 of file ALStructure.h.
Referenced by getDecHead(), insertNew(), and remove().
ALElement* ALStructure::raHead [private] |
Definition at line 59 of file ALStructure.h.
Referenced by getRaHead(), insertNew(), and remove().
ALNode* ALStructure::rootNode [private] |
Definition at line 63 of file ALStructure.h.
Referenced by add(), ALStructure(), findLowerBound(), removeNode(), and ~ALStructure().
ALElement ALStructure::sentinel [private] |
Definition at line 58 of file ALStructure.h.
Referenced by ALStructure().
unsigned int ALStructure::size [private] |
Definition at line 56 of file ALStructure.h.
Referenced by getSize(), insertNew(), and remove().
ALElement* ALStructure::tail [private] |
Definition at line 61 of file ALStructure.h.
Referenced by add(), findLowerBound(), and getTail().