OpenBarnyard
 
Loading...
Searching...
No Matches
T2RedBlackTree< T >::CIterator Class Reference

#include <T2RedBlackTree.h>

Public Member Functions

TFORCEINLINE CIterator (const Node *a_pNode)
 
TFORCEINLINE CIterator (const Iterator &a_rcIterator)
 
TFORCEINLINE CIterator Next ()
 
TFORCEINLINE CIterator Prev ()
 
TFORCEINLINE const NodeGetNode ()
 
TFORCEINLINE const T * GetValue () const
 
TFORCEINLINE TBOOL operator== (const Iterator &other) const
 
TFORCEINLINE TBOOL operator== (const CIterator &other) const
 
TFORCEINLINE const T & operator* () const
 
TFORCEINLINE const T * operator-> () const
 
TFORCEINLINE operator const T * () const
 
TFORCEINLINE CIterator operator++ (TINT)
 
TFORCEINLINE CIteratoroperator++ ()
 
TFORCEINLINE CIterator operator-- (TINT)
 
TFORCEINLINE CIteratoroperator-- ()
 

Friends

class Iterator
 

Detailed Description

template<class T>
class T2RedBlackTree< T >::CIterator

Definition at line 261 of file T2RedBlackTree.h.

Constructor & Destructor Documentation

◆ CIterator() [1/2]

template<class T>
TFORCEINLINE T2RedBlackTree< T >::CIterator::CIterator ( const Node * a_pNode)
inline

Definition at line 264 of file T2RedBlackTree.h.

265 : m_pNode( a_pNode ) {}

◆ CIterator() [2/2]

template<class T>
TFORCEINLINE T2RedBlackTree< T >::CIterator::CIterator ( const Iterator & a_rcIterator)
inline

Definition at line 267 of file T2RedBlackTree.h.

268 : m_pNode( a_rcIterator.m_pNode ) {}

Member Function Documentation

◆ GetNode()

template<class T>
TFORCEINLINE const Node * T2RedBlackTree< T >::CIterator::GetNode ( )
inline

Definition at line 284 of file T2RedBlackTree.h.

285 {
286 return m_pNode;
287 }

◆ GetValue()

template<class T>
TFORCEINLINE const T * T2RedBlackTree< T >::CIterator::GetValue ( ) const
inline

Definition at line 289 of file T2RedBlackTree.h.

290 {
291 return &m_pNode->m_Value;
292 }

◆ Next()

template<class T>
TFORCEINLINE CIterator T2RedBlackTree< T >::CIterator::Next ( )
inline

Definition at line 270 of file T2RedBlackTree.h.

271 {
272 CIterator next = *this;
273 m_pNode = TSTATICCAST( const Node, T2RedBlackTree::GetSuccessorOf( m_pNode ) );
274 return next;
275 }
#define TSTATICCAST(POINTERTYPE, VALUE)
Definition Defines.h:69
TFORCEINLINE CIterator(const Node *a_pNode)

◆ operator const T *()

template<class T>
TFORCEINLINE T2RedBlackTree< T >::CIterator::operator const T * ( ) const
inline

Definition at line 314 of file T2RedBlackTree.h.

315 {
316 return &m_pNode->m_Value;
317 }

◆ operator*()

template<class T>
TFORCEINLINE const T & T2RedBlackTree< T >::CIterator::operator* ( ) const
inline

Definition at line 304 of file T2RedBlackTree.h.

305 {
306 return m_pNode->m_Value;
307 }

◆ operator++() [1/2]

template<class T>
TFORCEINLINE CIterator & T2RedBlackTree< T >::CIterator::operator++ ( )
inline

Definition at line 324 of file T2RedBlackTree.h.

325 {
326 m_pNode = TSTATICCAST( const Node, T2RedBlackTree::GetSuccessorOf( m_pNode ) );
327 return *this;
328 }

◆ operator++() [2/2]

template<class T>
TFORCEINLINE CIterator T2RedBlackTree< T >::CIterator::operator++ ( TINT )
inline

Definition at line 319 of file T2RedBlackTree.h.

320 {
321 return Next();
322 }
TFORCEINLINE CIterator Next()

◆ operator--() [1/2]

template<class T>
TFORCEINLINE CIterator & T2RedBlackTree< T >::CIterator::operator-- ( )
inline

Definition at line 335 of file T2RedBlackTree.h.

336 {
337 m_pNode = TSTATICCAST( const Node, T2RedBlackTree::GetPredecessorOf( m_pNode ) );
338 return *this;
339 }

◆ operator--() [2/2]

template<class T>
TFORCEINLINE CIterator T2RedBlackTree< T >::CIterator::operator-- ( TINT )
inline

Definition at line 330 of file T2RedBlackTree.h.

331 {
332 return Prev();
333 }
TFORCEINLINE CIterator Prev()

◆ operator->()

template<class T>
TFORCEINLINE const T * T2RedBlackTree< T >::CIterator::operator-> ( ) const
inline

Definition at line 309 of file T2RedBlackTree.h.

310 {
311 return &m_pNode->m_Value;
312 }

◆ operator==() [1/2]

template<class T>
TFORCEINLINE TBOOL T2RedBlackTree< T >::CIterator::operator== ( const CIterator & other) const
inline

Definition at line 299 of file T2RedBlackTree.h.

300 {
301 return m_pNode == other.m_pNode;
302 }

◆ operator==() [2/2]

template<class T>
TFORCEINLINE TBOOL T2RedBlackTree< T >::CIterator::operator== ( const Iterator & other) const
inline

Definition at line 294 of file T2RedBlackTree.h.

295 {
296 return m_pNode == other.m_pNode;
297 }

◆ Prev()

template<class T>
TFORCEINLINE CIterator T2RedBlackTree< T >::CIterator::Prev ( )
inline

Definition at line 277 of file T2RedBlackTree.h.

278 {
279 CIterator prev = *this;
280 m_pNode = TSTATICCAST( const Node, T2RedBlackTree::GetPredecessorOf( m_pNode ) );
281 return prev;
282 }

Friends And Related Symbol Documentation

◆ Iterator

template<class T>
friend class Iterator
friend

Definition at line 344 of file T2RedBlackTree.h.


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