26 std::string_view colName,
27 std::string_view typeName)
41 const auto readerArraySize = readerArray.GetSize();
48 assert(readerArray.IsContiguous() &&
"std::array storage should always be contiguous");
50 if (readerArraySize > 0) {
71 const auto readerArraySize = readerArray.GetSize();
78 if (readerArraySize > 0) {
82 assert(
fValueSize > 0 &&
"Could not retrieve size of collection value type.");
86 for (std::size_t i{0}; i < readerArraySize; i++) {
87 auto val = readerArray.At(i);
105 const auto readerArraySize = readerArray.GetSize();
112 if (readerArraySize > 0) {
125 Warning(
"RTreeColumnReader::Get",
126 "Branch %s hangs from a non-split branch. A copy is being performed in order "
127 "to properly read the content.",
128 readerArray.GetBranchName());
134 if (readerArraySize > 0) {
138 assert(
fValueSize > 0 &&
"Could not retrieve size of collection value type.");
142 for (std::size_t i{0}; i < readerArraySize; i++) {
143 auto val = readerArray.At(i);
153 fRVec.set_size(readerArraySize);
175 std::string_view colName,
176 std::string_view valueTypeName,
186 TTreeReader &
r, std::unique_ptr<ROOT::Detail::RDF::RColumnReaderBase> valueReader, std::string_view maskName,
187 unsigned int maskIndex)
#define R__unlikely(expr)
long long Long64_t
Portable signed long integer 8 bytes.
void Warning(const char *location, const char *msgfmt,...)
Use this function in warning situations.
std::unique_ptr< TTreeReaderValue< uint64_t > > fTreeValueMask
std::unique_ptr< ROOT::Detail::RDF::RColumnReaderBase > fValueReader
~RMaskedColumnReader() override
void * GetImpl(Long64_t) override
RMaskedColumnReader(TTreeReader &r, std::unique_ptr< ROOT::Detail::RDF::RColumnReaderBase > valueReader, std::string_view maskName, unsigned int maskIndex)
std::unique_ptr< ROOT::Internal::TTreeReaderOpaqueValue > fTreeValue
void * GetImpl(Long64_t) override
RTreeOpaqueColumnReader(TTreeReader &r, std::string_view colName)
Construct the RTreeColumnReader. Actual initialization is performed lazily by the Init method.
~RTreeOpaqueColumnReader() final
bool fCopyWarningPrinted
Whether we already printed a warning about performing a copy of the TTreeReaderArray contents.
ECollectionType fCollectionType
void * GetImpl(Long64_t entry) override
~RTreeUntypedArrayColumnReader() final
void * ReadRVec(Long64_t entry)
RTreeUntypedArrayColumnReader(TTreeReader &r, std::string_view colName, std::string_view valueTypeName, ECollectionType collType)
void * ReadStdArray(Long64_t entry)
RVec< Byte_t > fRVec
We return a reference to this RVec to clients, to guarantee a stable address and contiguous memory la...
std::unique_ptr< ROOT::Internal::TTreeReaderUntypedArray > fTreeArray
std::vector< Byte_t > fStdVector
When the user explicitly requests std::vector<T>, we use this std::vector as a stable storage.
void * ReadStdVector(Long64_t entry)
std::size_t fValueSize
The size of the collection value type.
RTreeUntypedValueColumnReader(TTreeReader &r, std::string_view colName, std::string_view typeName)
void * GetImpl(Long64_t) override
std::unique_ptr< ROOT::Internal::TTreeReaderUntypedValue > fTreeValue
~RTreeUntypedValueColumnReader() final
Read a value in a branch without knowledge of its type.
@ kReadError
Problem reading data.
A "std::vector"-like collection of values implementing handy operation to analyse them.
An interface for reading values stored in ROOT columnar datasets.
A simple, robust and fast interface to read values from ROOT columnar datasets such as TTree,...