Iterate through the entries of a TTree.
This iterator drives the associated TTreeReader; its dereferencing (and actually even the iteration) will set the entry number represented by this iterator. It does not really represent a data element; it simply returns the entry number (or -1 once the end of the tree is reached).
Definition at line 58 of file TTreeReader.h.
Public Types | |
using | const_pointer = const Long64_t * |
using | difference_type = Long64_t |
using | iterator_category = std::input_iterator_tag |
using | pointer = const Long64_t * |
using | reference = const Long64_t & |
using | value_type = const Long64_t |
Public Member Functions | |
Iterator_t () | |
Default-initialize the iterator as "past the end". | |
Iterator_t (TTreeReader &reader, Long64_t entry) | |
Initialize the iterator with the reader it steers and a tree entry number; -1 is invalid. | |
bool | operator!= (const Iterator_t &lhs) const |
Compare two iterators for inequality. | |
const Long64_t & | operator* () |
Set the entry number in the reader and return it. | |
const Long64_t & | operator* () const |
Iterator_t & | operator++ () |
Increment the iterator (prefix ++i). | |
Iterator_t | operator++ (int) |
Increment the iterator (postfix i++). | |
bool | operator== (const Iterator_t &lhs) const |
Compare two iterators for equality. | |
Private Member Functions | |
bool | IsValid () const |
Whether the iterator points to a valid entry. | |
Private Attributes | |
Long64_t | fEntry |
Entry number of the tree referenced by this iterator; -1 is invalid. | |
TTreeReader * | fReader |
The reader we select the entries on. | |
#include <TTreeReader.h>
using TTreeReader::Iterator_t::const_pointer = const Long64_t * |
Definition at line 71 of file TTreeReader.h.
Definition at line 69 of file TTreeReader.h.
using TTreeReader::Iterator_t::iterator_category = std::input_iterator_tag |
Definition at line 67 of file TTreeReader.h.
using TTreeReader::Iterator_t::pointer = const Long64_t * |
Definition at line 70 of file TTreeReader.h.
using TTreeReader::Iterator_t::reference = const Long64_t & |
Definition at line 72 of file TTreeReader.h.
using TTreeReader::Iterator_t::value_type = const Long64_t |
Definition at line 68 of file TTreeReader.h.
|
inline |
Default-initialize the iterator as "past the end".
Definition at line 75 of file TTreeReader.h.
|
inline |
Initialize the iterator with the reader it steers and a tree entry number; -1 is invalid.
Definition at line 79 of file TTreeReader.h.
|
inlineprivate |
Whether the iterator points to a valid entry.
Definition at line 64 of file TTreeReader.h.
|
inline |
Compare two iterators for inequality.
Definition at line 109 of file TTreeReader.h.
|
inline |
Set the entry number in the reader and return it.
Definition at line 134 of file TTreeReader.h.
|
inline |
Definition at line 145 of file TTreeReader.h.
|
inline |
Increment the iterator (prefix ++i).
Definition at line 121 of file TTreeReader.h.
|
inline |
Increment the iterator (postfix i++).
Definition at line 114 of file TTreeReader.h.
|
inline |
Compare two iterators for equality.
Definition at line 83 of file TTreeReader.h.
|
private |
Entry number of the tree referenced by this iterator; -1 is invalid.
Definition at line 60 of file TTreeReader.h.
|
private |
The reader we select the entries on.
Definition at line 61 of file TTreeReader.h.