|
ACTS
Experiment-independent tracking
|
Grid iterator using the global position. More...
#include <Acts/Utilities/GridIterator.hpp>
Public Types | |
| using | difference_type = std::ptrdiff_t |
| Type for iterator arithmetic. | |
| using | iterator_category = std::random_access_iterator_tag |
| Iterator category for standard algorithms. | |
| using | pointer = value_type* |
| Pointer type to grid values. | |
| using | reference = value_type& |
| Reference type to grid values. | |
| using | value_type = T |
| Type of values stored in grid bins. | |
Public Member Functions | |
| GridGlobalIterator ()=default | |
| Default constructor. | |
| GridGlobalIterator (const Grid< T, Axes... > &grid, std::size_t idx=0ul) | |
| Constructor not taking ownership of the grid. | |
| GridGlobalIterator (const GridGlobalIterator< T, Axes... > &other)=default | |
| Copy constructor. | |
| GridGlobalIterator (Grid< T, Axes... > &&grid, std::size_t idx)=delete | |
| Constructor taking ownership of the grid is not allowed. | |
| GridGlobalIterator (GridGlobalIterator< T, Axes... > &&other) noexcept | |
| Move constructor. | |
| ~GridGlobalIterator ()=default | |
| Default destructor. | |
| std::size_t | globalBinIndex () const |
| Retrieve the global bin index. | |
| std::array< std::size_t, DIM > | localBinsIndices () const |
| Retrieve the local bins indices. | |
| const value_type & | operator* () const |
| Return stored value at given global position. | |
| GridGlobalIterator< T, Axes... > | operator+ (const std::size_t offset) const |
| Create incremented iterator. | |
| GridGlobalIterator< T, Axes... > & | operator++ () |
| Increment operator (pre). | |
| GridGlobalIterator< T, Axes... > | operator++ (int) |
| Increment operator (post). | |
| GridGlobalIterator< T, Axes... > & | operator+= (const std::size_t offset) |
| Increment this iterator with an offset. | |
| difference_type | operator- (const GridGlobalIterator< T, Axes... > &other) const |
| Distance between two GridGlobalIterators. | |
| GridGlobalIterator< T, Axes... > | operator- (const std::size_t offset) const |
| Create decremented iterator. | |
| GridGlobalIterator< T, Axes... > & | operator-= (const std::size_t offset) |
| Decrement this iterator with an offset. | |
| auto | operator<=> (const GridGlobalIterator< T, Axes... > &other) const |
| Comparison (<=>) operator. | |
| GridGlobalIterator< T, Axes... > & | operator= (const GridGlobalIterator< T, Axes... > &other)=default |
| Copy assignment. | |
| GridGlobalIterator< T, Axes... > & | operator= (GridGlobalIterator< T, Axes... > &&other) noexcept |
| Move assignment. | |
| bool | operator== (const GridGlobalIterator< T, Axes... > &other) const |
| Equality operator. | |
Static Public Attributes | |
| static constexpr std::size_t | DIM = sizeof...(Axes) |
| Dimensionality of the grid (number of axes). | |
Grid iterator using the global position.
This iterates on all the bins in the grid, including under- and over-flows
| T | The type stored in the grid bins |
| Axes | ... The types of the axes in the grid |
| using Acts::GridGlobalIterator< T, Axes >::difference_type = std::ptrdiff_t |
Type for iterator arithmetic.
| using Acts::GridGlobalIterator< T, Axes >::iterator_category = std::random_access_iterator_tag |
Iterator category for standard algorithms.
| using Acts::GridGlobalIterator< T, Axes >::pointer = value_type* |
Pointer type to grid values.
| using Acts::GridGlobalIterator< T, Axes >::reference = value_type& |
Reference type to grid values.
| using Acts::GridGlobalIterator< T, Axes >::value_type = T |
Type of values stored in grid bins.
|
default |
Default constructor.
|
delete |
Constructor taking ownership of the grid is not allowed.
| [in] | grid | The grid |
| [in] | idx | The global bin |
|
explicit |
Constructor not taking ownership of the grid.
| [in] | grid | The grid |
| [in] | idx | The global bin |
|
default |
Copy constructor.
| [in] | other | The GlobalBinIterator to be copied |
|
noexcept |
Move constructor.
| [in] | other | The GlobalBinIterator to be moved |
This will invalidate the other GlobalBinIterator
|
default |
Default destructor.
| std::size_t Acts::GridGlobalIterator< T, Axes >::globalBinIndex | ( | ) | const |
Retrieve the global bin index.
| std::array< std::size_t, DIM > Acts::GridGlobalIterator< T, Axes >::localBinsIndices | ( | ) | const |
Retrieve the local bins indices.
| const value_type & Acts::GridGlobalIterator< T, Axes >::operator* | ( | ) | const |
Return stored value at given global position.
| GridGlobalIterator< T, Axes... > Acts::GridGlobalIterator< T, Axes >::operator+ | ( | const std::size_t | offset | ) | const |
Create incremented iterator.
| [in] | offset | The increment value |
| GridGlobalIterator< T, Axes... > & Acts::GridGlobalIterator< T, Axes >::operator++ | ( | ) |
Increment operator (pre).
This will increase the global position by one
| GridGlobalIterator< T, Axes... > Acts::GridGlobalIterator< T, Axes >::operator++ | ( | int | ) |
Increment operator (post).
This will increase the global position by one
| GridGlobalIterator< T, Axes... > & Acts::GridGlobalIterator< T, Axes >::operator+= | ( | const std::size_t | offset | ) |
Increment this iterator with an offset.
| [in] | offset | The increment value |
| difference_type Acts::GridGlobalIterator< T, Axes >::operator- | ( | const GridGlobalIterator< T, Axes... > & | other | ) | const |
Distance between two GridGlobalIterators.
| [in] | other | The other GridGlobalIterator |
This will compute the distance by comparing the global positions in the two iterators
| GridGlobalIterator< T, Axes... > Acts::GridGlobalIterator< T, Axes >::operator- | ( | const std::size_t | offset | ) | const |
Create decremented iterator.
| [in] | offset | The decrement value |
| GridGlobalIterator< T, Axes... > & Acts::GridGlobalIterator< T, Axes >::operator-= | ( | const std::size_t | offset | ) |
Decrement this iterator with an offset.
| [in] | offset | The decrement value |
| auto Acts::GridGlobalIterator< T, Axes >::operator<=> | ( | const GridGlobalIterator< T, Axes... > & | other | ) | const |
Comparison (<=>) operator.
| [in] | other | The other GridGlobalIterator to be compared against this one |
|
default |
Copy assignment.
| [in] | other | The GlobalBinIterator to be copied |
|
noexcept |
Move assignment.
| [in] | other | The GlobalBinIterator to be moved |
This will invalidate the other GlobalBinIterator
| bool Acts::GridGlobalIterator< T, Axes >::operator== | ( | const GridGlobalIterator< T, Axes... > & | other | ) | const |
Equality operator.
| [in] | other | The other GridGlobalIterator to be compared against this one |
|
staticconstexpr |
Dimensionality of the grid (number of axes).