5#ifndef ROOT_RBinIndexMultiDimRange
6#define ROOT_RBinIndexMultiDimRange
17namespace Experimental {
50 return lhs.fRanges ==
rhs.fRanges;
74 using pointer =
const std::vector<RBinIndex> *;
86 const std::size_t i =
N - 1 -
j;
104 for (std::size_t k = 0; k <
j; k++) {
106 const std::size_t i =
N - 1 - k;
125 return lhs.fIterators ==
rhs.fIterators &&
lhs.fMultiDimRange ==
rhs.fMultiDimRange;
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
Iterator over RBinIndexMultiDimRange.
friend bool operator!=(const RIterator &lhs, const RIterator &rhs)
RIterator(const RBinIndexMultiDimRange &multiDimRange)
std::vector< RBinIndexRange::RIterator > fIterators
The current iterators.
std::vector< RBinIndex > value_type
const std::vector< RBinIndex > & operator*() const
const std::vector< RBinIndex > * operator->() const
const RBinIndexMultiDimRange * fMultiDimRange
Pointer to the original RBinIndexMultiDimRange.
const std::vector< RBinIndex > & reference
std::vector< RBinIndex > fIndices
The current bin indices.
const std::vector< RBinIndex > * pointer
std::input_iterator_tag iterator_category
std::ptrdiff_t difference_type
RIterator operator++(int)
friend bool operator==(const RIterator &lhs, const RIterator &rhs)
A multidimensional range of bin indices.
bool fHasEmptyRange
Whether there is an empty range.
RBinIndexMultiDimRange()=default
Construct an invalid bin index range.
std::vector< RBinIndexRange > fRanges
The original ranges.
friend bool operator==(const RBinIndexMultiDimRange &lhs, const RBinIndexMultiDimRange &rhs)
friend bool operator!=(const RBinIndexMultiDimRange &lhs, const RBinIndexMultiDimRange &rhs)
const std::vector< RBinIndexRange > & GetRanges() const
RBinIndexMultiDimRange(std::vector< RBinIndexRange > ranges)
Construct a multidimensional range of bin indices.
const_iterator begin() const