FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType Class Reference


Detailed Description

template<typename DATA_TYPE, typename KEY_COMPARE_FUNCTOR, typename ALLOCATOR>
class FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType

This class represents a node in the tree.

It contains the key, the value, and internal tree management data.

Definition at line 245 of file fbxmap.h.

#include <fbxmap.h>

List of all members.

Public Member Functions

ConstKeyType GetKey () const
ConstValueType GetValue () const
ValueType GetValue ()
const RecordType Minimum () const
RecordType Minimum ()
const RecordType Maximum () const
RecordType Maximum ()
const RecordType Predecessor () const
RecordType Predecessor ()
const RecordType Successor () const
RecordType Successor ()
const int  GetBlackDepth ()

Friends

class  FbxRedBlackTree

Member Function Documentation

ConstKeyType& GetKey ( ) const [inline]

Definition at line 248 of file fbxmap.h.

{ return mData.GetKey(); }
ConstValueType& GetValue ( ) const [inline]

Definition at line 249 of file fbxmap.h.

{ return mData.GetValue(); }
ValueType& GetValue ( ) [inline]

Definition at line 250 of file fbxmap.h.

{ return mData.GetValue(); }
const RecordType* Minimum ( ) const [inline]

Definition at line 252 of file fbxmap.h.

        {
            const RecordType* lParent = 0;
            const RecordType* lNode = this;
            while (lNode != 0)
            {
                lParent = lNode;
                lNode = lNode->mLeftChild;
            }

            return lParent;
        }
RecordType* Minimum ( ) [inline]

Definition at line 265 of file fbxmap.h.

        {
            RecordType* lParent = 0;
            RecordType* lNode = this;
            while (lNode != 0)
            {
                lParent = lNode;
                lNode = lNode->mLeftChild;
            }

            return lParent;
        }
const RecordType* Maximum ( ) const [inline]

Definition at line 278 of file fbxmap.h.

        {
            const RecordType* lParent = 0;
            const RecordType* lNode = this;
            while (lNode != 0)
            {
                lParent = lNode;
                lNode = lNode->mRightChild;
            }

            return lParent;
        }
RecordType* Maximum ( ) [inline]

Definition at line 291 of file fbxmap.h.

        {
            RecordType* lParent = 0;
            RecordType* lNode = this;
            while (lNode != 0)
            {
                lParent = lNode;
                lNode = lNode->mRightChild;
            }

            return lParent;
        }
const RecordType* Predecessor ( ) const [inline]

Definition at line 304 of file fbxmap.h.

        {
            if (mLeftChild)
            {
                return mLeftChild->Maximum();
            }
            else
            {
                const RecordType* lParent = mParent;
                const RecordType* lNode = this;

                while (lParent && lParent->mLefttChild == lNode)
                {
                    lNode = lParent;
                    lParent = lParent->mParent;
                }

                return lParent;
            }
        }
RecordType* Predecessor ( ) [inline]

Definition at line 325 of file fbxmap.h.

        {
            if (mLeftChild)
            {
                return mLeftChild->Maximum();
            }
            else
            {
                RecordType* lParent = mParent;
                RecordType* lNode = this;

                while (lParent && lParent->mLeftChild == lNode)
                {
                    lNode = lParent;
                    lParent = lParent->mParent;
                }

                return lParent;
            }
        }
const RecordType* Successor ( ) const [inline]

Definition at line 346 of file fbxmap.h.

        {
            if (mRightChild)
            {
                return mRightChild->Minimum();
            }
            else
            {
                const RecordType* lParent = mParent;
                const RecordType* lNode = this;

                while (lParent && lParent->mRightChild == lNode)
                {
                    lNode = lParent;
                    lParent = lParent->mParent;
                }

                return lParent;
            }
        }
RecordType* Successor ( ) [inline]

Definition at line 367 of file fbxmap.h.

        {
            if (mRightChild)
            {
                return mRightChild->Minimum();
            }
            else
            {
                RecordType* lParent = mParent;
                RecordType* lNode = this;

                while (lParent && lParent->mRightChild == lNode)
                {
                    lNode = lParent;
                    lParent = lParent->mParent;
                }

                return lParent;
            }
        }
const int GetBlackDepth ( ) [inline]

Definition at line 388 of file fbxmap.h.

{ return mBlackDepth; }

Friends And Related Function Documentation

friend class FbxRedBlackTree [friend]

Definition at line 415 of file fbxmap.h.


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

FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType
FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType FbxRedBlackTree< DATA_TYPE, KEY_COMPARE_FUNCTOR, ALLOCATOR >::RecordType