Processor specialization for horizontally combined (joined) RNTuples.
Definition at line 529 of file RNTupleProcessor.hxx.
Private Member Functions | |
RNTupleJoinProcessor (const RNTupleOpenSpec &mainNTuple, const std::vector< RNTupleOpenSpec > &auxNTuples, const std::vector< std::string > &joinFields, std::string_view processorName, std::unique_ptr< ROOT::RNTupleModel > primaryModel=nullptr, std::vector< std::unique_ptr< ROOT::RNTupleModel > > auxModels={}) | |
Construct a new RNTupleJoinProcessor. | |
void | ConnectFields () |
Connect all fields, once the primary and all auxiliary RNTuples have been added. | |
ROOT::NTupleSize_t | GetNEntries () final |
Get the total number of entries in this processor. | |
bool | HasJoinTable () const |
ROOT::NTupleSize_t | LoadEntry (ROOT::NTupleSize_t entryNumber) final |
Load the entry identified by the provided entry number of the primary RNTuple. | |
void | SetEntryPointers (const ROOT::REntry &) final |
void | SetJoinFieldTokens (const std::vector< std::string > &joinFields) |
Populate fJoinFieldTokens with tokens for join fields belonging to the main RNTuple in the join model. | |
void | SetModel (std::unique_ptr< ROOT::RNTupleModel > primaryModel, std::vector< std::unique_ptr< ROOT::RNTupleModel > > auxModels) |
Set fModel by combining the primary and auxiliary models. | |
Private Attributes | |
std::vector< std::unique_ptr< ROOT::Internal::RPageSource > > | fAuxiliaryPageSources |
std::vector< ROOT::RFieldToken > | fJoinFieldTokens |
Tokens representing the join fields present in the main RNTuple. | |
std::vector< std::unique_ptr< Internal::RNTupleJoinTable > > | fJoinTables |
bool | fJoinTablesAreBuilt = false |
Friends | |
class | RNTupleProcessor |
Additional Inherited Members | |
![]() | |
static std::unique_ptr< RNTupleProcessor > | Create (RNTupleOpenSpec ntuple, std::string_view processorName, std::unique_ptr< ROOT::RNTupleModel > model=nullptr) |
Create an RNTupleProcessor for a single RNTuple. | |
static std::unique_ptr< RNTupleProcessor > | Create (RNTupleOpenSpec ntuple, std::unique_ptr< ROOT::RNTupleModel > model=nullptr) |
Create an RNTupleProcessor for a single RNTuple. | |
static std::unique_ptr< RNTupleProcessor > | CreateChain (std::vector< RNTupleOpenSpec > ntuples, std::string_view processorName, std::unique_ptr< ROOT::RNTupleModel > model=nullptr) |
Create an RNTupleProcessor for a chain (i.e., a vertical combination) of RNTuples. | |
static std::unique_ptr< RNTupleProcessor > | CreateChain (std::vector< RNTupleOpenSpec > ntuples, std::unique_ptr< ROOT::RNTupleModel > model=nullptr) |
Create an RNTupleProcessor for a chain (i.e., a vertical combination) of RNTuples. | |
static std::unique_ptr< RNTupleProcessor > | CreateChain (std::vector< std::unique_ptr< RNTupleProcessor > > innerProcessors, std::string_view processorName, std::unique_ptr< ROOT::RNTupleModel > model=nullptr) |
Create an RNTupleProcessor for a chain (i.e., a vertical combination) of other RNTupleProcessors. | |
static std::unique_ptr< RNTupleProcessor > | CreateChain (std::vector< std::unique_ptr< RNTupleProcessor > > innerProcessors, std::unique_ptr< ROOT::RNTupleModel > model=nullptr) |
Create an RNTupleProcessor for a chain (i.e., a vertical combination) of other RNTupleProcessors. | |
static std::unique_ptr< RNTupleProcessor > | CreateJoin (const RNTupleOpenSpec &primaryNTuple, const std::vector< RNTupleOpenSpec > &auxNTuples, const std::vector< std::string > &joinFields, std::string_view processorName, std::unique_ptr< ROOT::RNTupleModel > primaryModel=nullptr, std::vector< std::unique_ptr< ROOT::RNTupleModel > > auxModels={}) |
Create an RNTupleProcessor for a join (i.e., a horizontal combination) of RNTuples. | |
static std::unique_ptr< RNTupleProcessor > | CreateJoin (const RNTupleOpenSpec &primaryNTuple, const std::vector< RNTupleOpenSpec > &auxNTuples, const std::vector< std::string > &joinFields, std::unique_ptr< ROOT::RNTupleModel > primaryModel=nullptr, std::vector< std::unique_ptr< ROOT::RNTupleModel > > auxModels={}) |
Create an RNTupleProcessor for a join (i.e., a horizontal combination) of RNTuples. | |
![]() | |
RNTupleProcessor (std::string_view processorName, std::unique_ptr< ROOT::RNTupleModel > model) | |
Create a new base RNTupleProcessor. | |
void | ConnectField (RFieldContext &fieldContext, ROOT::Internal::RPageSource &pageSource, ROOT::REntry &entry) |
Create and connect a concrete field to the current page source, based on its proto field. | |
![]() | |
ROOT::NTupleSize_t | fCurrentEntryNumber = 0 |
std::size_t | fCurrentProcessorNumber = 0 |
std::unique_ptr< ROOT::REntry > | fEntry |
std::unordered_map< std::string, RFieldContext > | fFieldContexts |
Maps the (qualified) field name to its corresponding field context. | |
std::unique_ptr< ROOT::RNTupleModel > | fModel |
ROOT::NTupleSize_t | fNEntries = kInvalidNTupleIndex |
Total number of entries. | |
ROOT::NTupleSize_t | fNEntriesProcessed = 0 |
std::vector< RNTupleOpenSpec > | fNTuples |
std::unique_ptr< ROOT::Internal::RPageSource > | fPageSource |
std::string | fProcessorName |
#include <ROOT/RNTupleProcessor.hxx>
|
private |
Construct a new RNTupleJoinProcessor.
[in] | mainNTuple | The source specification (name and storage location) of the primary RNTuple. |
[in] | auxNTUples | The source specifications (name and storage location) of the auxiliary RNTuples. |
[in] | joinFields | The names of the fields on which to join, in case the specified RNTuples are unaligned. The join is made based on the combined join field values, and therefore each field has to be present in each specified RNTuple. If an empty list is provided, it is assumed that the RNTuples are fully aligned. |
[in] | processorName | Name of the processor. Unless specified otherwise in RNTupleProcessor::CreateJoin, this is the name of the main RNTuple. |
[in] | primaryModel | An RNTupleModel specifying which fields from the primary RNTuple can be read by the processor. If no model is provided, one will be created based on the descriptor of the primary RNTuple. |
[in] | auxModels | A list of RNTupleModels specifying which fields from the corresponding auxiliary RNTuple (according to the order of auxNTuples ) can be read by the processor. If this vector is empty, the models will be created based on the descriptors of their corresponding RNTuples. This also applies to individual auxiliary RNTuples for which the provided model is a nullptr . |
Definition at line 343 of file RNTupleProcessor.cxx.
|
delete |
|
delete |
|
inlineoverride |
Definition at line 609 of file RNTupleProcessor.hxx.
|
private |
Connect all fields, once the primary and all auxiliary RNTuples have been added.
Definition at line 458 of file RNTupleProcessor.cxx.
|
inlinefinalprivatevirtual |
Get the total number of entries in this processor.
Implements ROOT::Experimental::RNTupleProcessor.
Definition at line 553 of file RNTupleProcessor.hxx.
|
inlineprivate |
Definition at line 539 of file RNTupleProcessor.hxx.
|
finalprivatevirtual |
Load the entry identified by the provided entry number of the primary RNTuple.
Implements ROOT::Experimental::RNTupleProcessor.
Definition at line 479 of file RNTupleProcessor.cxx.
|
delete |
|
delete |
|
finalprivatevirtual |
Implements ROOT::Experimental::RNTupleProcessor.
Definition at line 467 of file RNTupleProcessor.cxx.
|
inlineprivate |
Populate fJoinFieldTokens with tokens for join fields belonging to the main RNTuple in the join model.
[in] | joinFields | The names of the fields used in the join. |
Definition at line 575 of file RNTupleProcessor.hxx.
|
private |
Set fModel by combining the primary and auxiliary models.
[in] | primaryModel | The model of the primary RNTuple. |
[in] | auxModels | Models of the auxiliary RNTuples. |
To prevent field name clashes when one or more models have fields with duplicate names, fields from each auxiliary model are stored as a anonymous record, and subsequently registered as subfields in the join model. This way, they can be accessed from the processor's entry as auxNTupleName.fieldName
.
Definition at line 418 of file RNTupleProcessor.cxx.
|
friend |
Definition at line 530 of file RNTupleProcessor.hxx.
|
private |
Definition at line 533 of file RNTupleProcessor.hxx.
|
private |
Tokens representing the join fields present in the main RNTuple.
Definition at line 535 of file RNTupleProcessor.hxx.
|
private |
Definition at line 536 of file RNTupleProcessor.hxx.
Definition at line 537 of file RNTupleProcessor.hxx.