- Main Page
- Classes
- Files
- Directories
- Examples

- Class List
- Class Hierarchy
- Class Members

Public Types | Public Member Functions | Friends

# FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator Class Reference

Search for all occurrences

## Detailed Description

### template<typename KEY, typename VALUE, typename HASH, class Destruct = FbxNoOpDestruct<VALUE>, class Comparator = FbxDefaultComparator<KEY>>
class FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator

Definition at line 60 of file fbxhashmap.h.

`#include <fbxhashmap.h>`

List of all members.

## Public Types
typedef ListItem | ListItemType
typedef FbxPair< KeyType, ValueType > | KeyValuePair
## Public Member Functions
| Iterator (const Iterator &pOther)
| ~Iterator ()
KeyValuePair | operator* () const
void | Next ()
bool | operator== (const Iterator &pOther) const
bool | operator!= (const Iterator &pOther) const
Iterator & | operator= (const Iterator &pOther)
## Friends
class | FbxHashMap

## Member Typedef Documentation

typedef ListItem ListItemType

Search for all occurrences

Definition at line 64 of file fbxhashmap.h.

typedef FbxPair< KeyType, ValueType > KeyValuePair

Search for all occurrences

Definition at line 65 of file fbxhashmap.h.

## Constructor & Destructor Documentation

Iterator | ( | const Iterator & | pOther | ) | `[inline]`

Definition at line 67 of file fbxhashmap.h.

                :
                mMap( pOther.mMap ),
                mBucketIndex( pOther.mBucketIndex ),
                mCurrentItem( pOther.mCurrentItem )
            {

            }

~Iterator | ( |  | ) | `[inline]`

Definition at line 76 of file fbxhashmap.h.

    {};

## Member Function Documentation

KeyValuePair operator* | ( |  | ) | const `[inline]`

Definition at line 78 of file fbxhashmap.h.

            {
                KeyValuePair lItem;

                if( mCurrentItem )
                {
                    lItem.mFirst = mCurrentItem->mKey;
                    lItem.mSecond = mCurrentItem->mValue;
                    return lItem;
                }

                FBX_ASSERT_NOW("Accessing out of bounds iterator");

                return lItem;
            }

void Next | ( |  | ) | `[inline]`

Search for all occurrences

Definition at line 94 of file fbxhashmap.h.

            {
                if( !mCurrentItem )
                    return;

                if( mCurrentItem->mNext )
                {
                    mCurrentItem = mCurrentItem->mNext;
                    return;
                }
                else
                {
                    mBucketIndex++;
                    for( ; mBucketIndex < mMap->mBuckets.GetCount(); ++mBucketIndex )
                    {
                        if( mMap->mBuckets[ mBucketIndex ] )
                        {
                            mCurrentItem = mMap->mBuckets[ mBucketIndex ];
                            return;
                        }
                    }

                    if( mBucketIndex >= mMap->mBuckets.GetCount() )
                    {
                        *this = mMap->End();
                        return;
                    }
                }
            }

bool operator== | ( | const Iterator & | pOther | ) | const `[inline]`

Definition at line 124 of file fbxhashmap.h.

            {
                return  mCurrentItem == pOther.mCurrentItem &&
                        mBucketIndex == pOther.mBucketIndex &&
                        mMap == pOther.mMap;
            }

bool operator!= | ( | const Iterator & | pOther | ) | const `[inline]`

Definition at line 131 of file fbxhashmap.h.

            {
                return !(*this == pOther);
            }

Iterator& operator= | ( | const Iterator & | pOther | ) | `[inline]`

Definition at line 137 of file fbxhashmap.h.

            {
                this->mBucketIndex = pOther.mBucketIndex;
                this->mMap = pOther.mMap;
                this->mCurrentItem = pOther.mCurrentItem;
                return *this;
            }

## Friends And Related Function Documentation

friend class FbxHashMap `[friend]`

Search for all occurrences

Definition at line 160 of file fbxhashmap.h.

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

- fbxsdk/core/base/fbxhashmap.h

FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator
FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator FbxHashMap< KEY, VALUE, HASH, Destruct, Comparator >::Iterator