Index   Main   Namespaces   Classes   Hierarchy   Annotated   Files   Compound   Global   Pages  
Classes | Public Member Functions | Private Member Functions | Static Private Attributes

SgNb4Iterator Class Reference

Iterator over all 4 neighbor points. More...

#include <SgNbIterator.h>

Inheritance diagram for SgNb4Iterator:
Inheritance graph
[legend]

List of all members.

Classes

struct  Precomp
 Precomputed neighbors. More...

Public Member Functions

 SgNb4Iterator (SgPoint p)
const T & operator* () const
void operator++ ()
 operator bool () const

Private Member Functions

 SgNb4Iterator (const SgNb4Iterator &)
 Not implemented.
SgNb4Iteratoroperator= (const SgNb4Iterator &)
 Not implemented.

Static Private Attributes

static const Precomp s_precomp

Detailed Description

Iterator over all 4 neighbor points.

Iterates in sorted order. See also SgNbIterator for an iterator that filters points off board, but needs access to current board.

Vertical and horizontal neighbors (a subset of SgNb8Iterator).

       0
       |
    1 -p- 2    e.g. next[2] = +WE
       |
       3
    

Definition at line 27 of file SgNbIterator.h.


Constructor & Destructor Documentation

SgNb4Iterator::SgNb4Iterator ( SgPoint  p  ) 

Definition at line 31 of file SgNbIterator.h.

References SgPointUtil::InBoardRange(), and SG_ASSERT.

SgNb4Iterator::SgNb4Iterator ( const SgNb4Iterator  )  [private]

Not implemented.


Member Function Documentation

template<typename T , int SIZE>
SgArray< T, SIZE >::Iterator::operator bool (  )  const [inherited]
template<typename T , int SIZE>
const T & SgArray< T, SIZE >::Iterator::operator* (  )  const [inherited]

Definition at line 154 of file SgArray.h.

References SgArray< T, SIZE >::Iterator::m_current, and SG_ASSERT.

template<typename T , int SIZE>
void SgArray< T, SIZE >::Iterator::operator++ (  )  [inherited]

Definition at line 161 of file SgArray.h.

References SgArray< T, SIZE >::Iterator::m_current.

SgNb4Iterator& SgNb4Iterator::operator= ( const SgNb4Iterator  )  [private]

Not implemented.


Member Data Documentation

Definition at line 46 of file SgNbIterator.h.


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


Sun Mar 13 2011 Doxygen 1.7.1