The const_iterator class.
More...
#include <HKLGenerator.h>
|
| void | advance (difference_type) |
| | Required for compilation in VS.
|
| |
| void | decrement () |
| |
| const Kernel::V3D & | dereference () const |
| | Returns a const reference to the currently pointed at HKL.
|
| |
| bool | equal (const const_iterator &other) const |
| | Returns true if other is at the same position.
|
| |
| void | increment () |
| | Increments HKL, l moves fastest, h moves slowest, wrapping around at the max for each index.
|
| |
The const_iterator class.
This class uses boost::iterator_facade to provide a const_iterator interface to HKLGenerator. This makes it very easy to use the standard library algorithms. It's a forward iterator, so it's not possible to use operator[] for random access of specific HKLs (this would have to be done on the generated container if that supports it).
While the iterators can be instantiated directly, the intention is to use HKLGenerator::begin() and HKLGenerator::end().
Definition at line 96 of file HKLGenerator.h.
◆ const_iterator() [1/3]
| Mantid::Geometry::HKLGenerator::const_iterator::const_iterator |
( |
| ) |
|
Default constructor, requirement from boost::iterator_facade.
Definition at line 62 of file HKLGenerator.cpp.
◆ const_iterator() [2/3]
| Mantid::Geometry::HKLGenerator::const_iterator::const_iterator |
( |
const Kernel::V3D & |
current | ) |
|
|
explicit |
Return an iterator with min = max = current.
Definition at line 66 of file HKLGenerator.cpp.
◆ const_iterator() [3/3]
| Mantid::Geometry::HKLGenerator::const_iterator::const_iterator |
( |
const Kernel::V3D & |
hklMin, |
|
|
const Kernel::V3D & |
hklMax |
|
) |
| |
|
explicit |
Return an iterator that can move from min to max, with current = min.
Definition at line 71 of file HKLGenerator.cpp.
◆ advance()
| void Mantid::Geometry::HKLGenerator::const_iterator::advance |
( |
difference_type |
| ) |
|
|
inlineprivate |
Required for compilation in VS.
Forward iterator can not be used that way, so the implementation does nothing.
Definition at line 121 of file HKLGenerator.h.
◆ decrement()
| void Mantid::Geometry::HKLGenerator::const_iterator::decrement |
( |
| ) |
|
|
inlineprivate |
◆ dereference()
| const Kernel::V3D & Mantid::Geometry::HKLGenerator::const_iterator::dereference |
( |
| ) |
const |
|
inlineprivate |
Returns a const reference to the currently pointed at HKL.
Definition at line 117 of file HKLGenerator.h.
◆ equal()
| bool Mantid::Geometry::HKLGenerator::const_iterator::equal |
( |
const const_iterator & |
other | ) |
const |
|
inlineprivate |
Returns true if other is at the same position.
Definition at line 112 of file HKLGenerator.h.
◆ increment()
| void Mantid::Geometry::HKLGenerator::const_iterator::increment |
( |
| ) |
|
|
private |
Increments HKL, l moves fastest, h moves slowest, wrapping around at the max for each index.
Definition at line 78 of file HKLGenerator.cpp.
◆ boost::iterator_core_access
| friend class boost::iterator_core_access |
|
friend |
◆ m_h
| int Mantid::Geometry::HKLGenerator::const_iterator::m_h |
|
private |
◆ m_hkl
| Kernel::V3D Mantid::Geometry::HKLGenerator::const_iterator::m_hkl |
|
private |
◆ m_hMax
| int Mantid::Geometry::HKLGenerator::const_iterator::m_hMax |
|
private |
◆ m_k
| int Mantid::Geometry::HKLGenerator::const_iterator::m_k |
|
private |
◆ m_kMax
| int Mantid::Geometry::HKLGenerator::const_iterator::m_kMax |
|
private |
◆ m_kMin
| int Mantid::Geometry::HKLGenerator::const_iterator::m_kMin |
|
private |
◆ m_l
| int Mantid::Geometry::HKLGenerator::const_iterator::m_l |
|
private |
◆ m_lMax
| int Mantid::Geometry::HKLGenerator::const_iterator::m_lMax |
|
private |
◆ m_lMin
| int Mantid::Geometry::HKLGenerator::const_iterator::m_lMin |
|
private |
The documentation for this class was generated from the following files: