39bool isContainerField(
const ROOT::RFieldDescriptor& fieldDesc,
54 TClass*
cl = TClass::GetClass(fieldDesc.GetTypeName().c_str());
60 ::Warning(
"::isPContainerField",
61 XAOD_MESSAGE(
"Couldn't get a dictionary for type \"%s\""),
62 fieldDesc.GetTypeName().c_str());
67 const std::type_info* root_ti =
cl->GetTypeInfo();
75 typeName.ReplaceAll(
"basic_string<char>",
"string");
76 ::TClass* newCl = ::TClass::GetClass(typeName);
78 root_ti = newCl->GetTypeInfo();
82 ::Error(
"::isContainerField",
83 XAOD_MESSAGE(
"Couldn't get an std::type_info object out of "
90 const std::type_info* aux_obj_ti =
93 ::Error(
"::isContainerField",
96 static_cast<int>(auxid));
99 const std::type_info* aux_vec_ti =
102 ::Error(
"::isContainerField",
105 static_cast<int>(auxid));
110 if (*root_ti == *aux_obj_ti) {
113 }
else if (*root_ti == *aux_vec_ti) {
121 if (
cl->GetCollectionProxy() && (*aux_vec_ti ==
typeid(std::vector<int>))) {
127 if (*cl2->GetTypeInfo() == *aux_vec_ti) {
143 aux_vec_cl->GetConversionStreamerInfo(cl,
cl->GetClassVersion())) {
149 aux_obj_cl->GetConversionStreamerInfo(cl,
cl->GetClassVersion())) {
154 ::Error(
"::isContainerField",
155 XAOD_MESSAGE(
"Couldn't determine if field describes a single "
156 "object or a container"));
157 ::Error(
"::isContainerField",
XAOD_MESSAGE(
"ROOT type : %s"),
159 ::Error(
"::isContainerField",
XAOD_MESSAGE(
"Object type: %s"),
161 ::Error(
"::isContainerField",
XAOD_MESSAGE(
"Vector type: %s"),
171 RFieldHandle(ROOT::RNTupleView<void> field,
SG::auxid_t auxid,
172 std::string_view prefix,
void*
object,
const std::type_info* ti)
173 : m_field(std::move(
field)),
183 if ((m_entry == entry) && (!m_needsRead)) {
184 return StatusCode::SUCCESS;
190 }
catch (
const ROOT::RException& e) {
191 ::Error(
"::RFieldInfo::getEntry",
192 "Failed to load entry %lld for field %s.%s: %s", entry,
196 return StatusCode::FAILURE;
202 return StatusCode::SUCCESS;
211 void* objectPtr() {
return m_object; }
214 const std::type_info* typeInfo()
const {
return m_typeInfo; }
217 void reset() { m_needsRead =
true; }
221 ROOT::RNTupleView<void> m_field;
225 std::string_view m_prefix;
227 void* m_object =
nullptr;
229 const std::type_info* m_typeInfo =
nullptr;
231 ::Long64_t m_entry = -1;
233 bool m_needsRead =
true;
237bool fieldExists(std::string_view fieldName,
238 ROOT::RNTupleReader& ntupleReader) {
241 return (ntupleReader.GetDescriptor().FindFieldId(fieldName) !=
242 std::numeric_limits<unsigned long>::max());
263 return StatusCode::SUCCESS;
268 return StatusCode::SUCCESS;
272 for (
const ROOT::RFieldBase* field :
273#
if ROOT_VERSION_CODE >= ROOT_VERSION(6, 35, 0)
274 m_inTuple->GetModel().GetConstFieldZero().GetConstSubfields()
276 m_inTuple->GetModel().GetConstFieldZero().GetSubFields()
281 const std::string fieldName = field->GetQualifiedFieldName();
284 if (
m_data.m_topStore && (fieldName ==
m_data.m_prefix)) {
287 for (
const ROOT::RFieldBase* subField :
288#
if ROOT_VERSION_CODE >= ROOT_VERSION(6, 35, 0)
289 field->GetConstSubfields()
291 field->GetSubFields()
296 const std::string& typeName = subField->GetTypeName();
299 if (typeName.starts_with(
"xAOD::") ||
300 typeName.starts_with(
"SG::") ||
301 typeName.starts_with(
"DMTest::") ||
302 typeName.starts_with(
"ILockable")) {
315 if (fieldName.starts_with(
m_data.m_dynPrefix) ==
false) {
318 if (fieldName ==
m_data.m_dynPrefix) {
319 ::Error(
"xAOD::RAuxStore::impl::scanInputNtuple",
320 "Dynamic field with empty name found on container: %s",
325 std::string_view auxName = fieldName;
326 std::string::size_type spos = auxName.find(
':');
327 if (spos != std::string::npos) {
328 auxName = auxName.substr(spos + 1);
338 return StatusCode::SUCCESS;
351 std::string* expectedClassName =
nullptr) {
355 const std::string typeName = field.GetTypeName();
356 ::TClass* expectedClass = ::TClass::GetClass(typeName.c_str());
357 if (expectedClassName) {
359 *expectedClassName = expectedClass->GetName();
361 *expectedClassName = typeName;
373 const std::type_info* ti =
nullptr;
376 ti = expectedClass->GetTypeInfo();
381 if (!expectedClass) {
382 ::Warning(
"xAOD::RAuxStore::impl::auxFieldType",
383 "Couldn't get the type of field \"%s\"",
384 field.GetFieldName().c_str());
386 ::TVirtualCollectionProxy* prox = expectedClass->GetCollectionProxy();
391 prox = cl2->GetCollectionProxy();
396 ::Warning(
"xAOD::RAuxStore::impl::auxFieldType",
397 "Couldn't get the type of field \"%s\"",
398 field.GetFieldName().c_str());
400 if (prox->GetValueClass()) {
401 ti = prox->GetValueClass()->GetTypeInfo();
425 std::string_view auxName) {
428 std::string expectedClassName;
429 const std::type_info* ti =
auxFieldType(field, &expectedClassName);
432 return StatusCode::SUCCESS;
441 const std::string auxNameStr{auxName};
444 m_data.m_auxIDs.insert(regAuxid);
445 return StatusCode::SUCCESS;
454 const std::string linkedAttr =
456 const std::string linkedFieldName =
458 const std::type_info* linkedTi =
nullptr;
459 if (::fieldExists(linkedFieldName, *
m_inTuple)) {
465 *linkedTi, linkedAttr,
"",
469 ::Error(
"xAOD::RAuxStore::setupAuxField",
470 "Could not find linked variable for %s type %s", auxName.data(),
471 expectedClassName.c_str());
477 registry.
getAuxID(*ti, auxNameStr,
"", flags, linkedAuxId);
488 if (typeName.starts_with(
"std::vector<"))
489 typeName.erase(0, 5);
490 std::string factoryClassName =
491 "SG::AuxTypeVectorFactory<" + typeName +
",allocator<" + typeName;
492 if (factoryClassName[factoryClassName.size() - 1] ==
'>') {
493 factoryClassName +=
' ';
495 factoryClassName +=
"> >";
498 ::TClass* factoryClass = TClass::GetClass(factoryClassName.c_str());
499 if (factoryClass && factoryClass->IsLoaded()) {
500 ::TClass* baseClass = ::TClass::GetClass(
"SG::IAuxTypeVectorFactory");
501 if (baseClass && baseClass->IsLoaded()) {
502 const Int_t offset = factoryClass->GetBaseClassOffset(baseClass);
504 void* factoryVoidPointer = factoryClass->New();
505 if (factoryVoidPointer) {
507 reinterpret_cast<unsigned long>(factoryVoidPointer) + offset;
512 std::unique_ptr<SG::IAuxTypeVectorFactory>(factory));
513 auxid = registry.
getAuxID(*ti, auxNameStr,
"", flags,
525 if (vectorClassName[vectorClassName.size() - 1] ==
'>') {
526 vectorClassName +=
' ';
528 vectorClassName +=
'>';
531 ::TClass* vectorClass = ::TClass::GetClass(vectorClassName.c_str());
532 if (vectorClass && vectorClass->IsLoaded()) {
533 auto factory = std::make_unique<TAuxVectorFactory>(vectorClass);
534 if (factory->tiAlloc()) {
535 const std::type_info* tiAlloc = factory->tiAlloc();
536 registry.
addFactory(*ti, *tiAlloc, std::move(factory));
538 std::string tiAllocName = factory->tiAllocName();
539 registry.
addFactory(*ti, tiAllocName, std::move(factory));
541 auxid = registry.
getAuxID(*ti, auxNameStr,
"",
544 ::Warning(
"xAOD::RAuxStore::setupAuxField",
545 "Couldn't find dictionary for type: %s",
546 vectorClassName.c_str());
553 ::Error(
"xAOD::RAuxStore::setupAuxField",
554 XAOD_MESSAGE(
"Dynamic ROOT vector factory not implemented for "
555 "linked types; field \"%s\""),
556 field.GetFieldName().c_str());
558 ::Error(
"xAOD::RAuxStore::setupAuxField",
559 XAOD_MESSAGE(
"Couldn't assign auxiliary ID to field \"%s\""),
560 field.GetFieldName().c_str());
562 return StatusCode::FAILURE;
566 m_data.m_auxIDs.insert(auxid);
567 return StatusCode::SUCCESS;
585 std::vector<std::unique_ptr<RFieldHandle> >
m_fields;
627 m_impl->m_missingFields.clear();
630 m_impl->m_inTuple = &reader;
636 return StatusCode::SUCCESS;
653 m_impl->m_outTuple = &writer;
664 return StatusCode::SUCCESS;
681 if (
m_data.m_transientStore && (getall != 99)) {
683 m_data.m_auxIDs -=
m_data.m_transientStore->getAuxIDs();
684 m_data.m_decorIDs -=
m_data.m_transientStore->getDecorIDs();
686 m_data.m_transientStore.reset();
692 if (!
m_data.m_isDecoration[auxid]) {
695 m_data.m_auxIDs.erase(auxid);
696 m_data.m_decorIDs.erase(auxid);
702 return StatusCode::SUCCESS;
706 for (
auto& field :
m_impl->m_fields) {
708 RETURN_CHECK(
"xAOD::RAuxStore::getEntry", field->getEntry(entry));
713 return StatusCode::SUCCESS;
723 const std::string fieldName =
724 std::format(
"{}{}",
m_data.m_dynPrefix,
726 void* fieldPtr =
const_cast<void*
>(
getIOData(
id));
728 entry.BindRawPtr(fieldName, fieldPtr);
730 entry.EmplaceNewValue(fieldName);
735 return StatusCode::SUCCESS;
742 for (
auto& field :
m_impl->m_fields) {
747 m_impl->m_inputScanned =
false;
753 return ((
m_impl->m_fields.size() > auxid) &&
m_impl->m_fields[auxid]);
762 assert(
m_impl->m_fields.size() > auxid);
763 assert(
m_impl->m_fields[auxid]);
766 return StatusCode::SUCCESS;
772 return (
m_impl->m_outTuple !=
nullptr);
785 if ((auxid < m_impl->m_missingFields.size()) &&
786 m_impl->m_missingFields[auxid]) {
787 return StatusCode::RECOVERABLE;
792 if (
m_impl->m_inTuple ==
nullptr) {
793 return StatusCode::RECOVERABLE;
797 if (
m_data.m_vecs.size() <= auxid) {
798 m_data.m_vecs.resize(auxid + 1);
800 if (
m_impl->m_fields.size() <= auxid) {
801 m_impl->m_fields.resize(auxid + 1);
808 if (
m_data.m_vecs[auxid]) {
809 return (
m_impl->m_fields[auxid] ? StatusCode::SUCCESS
810 : StatusCode::RECOVERABLE);
817 const std::string statFieldName =
818 std::format(
"{}{}",
m_data.m_prefix,
r.getName(auxid));
819 const std::string dynFieldName =
820 std::format(
"{}{}",
m_data.m_dynPrefix,
r.getName(auxid));
823 std::string fieldName = statFieldName;
824 ROOT::DescriptorId_t fieldId;
825 if ((fieldId =
m_impl->m_inTuple->GetDescriptor().FindFieldId(
826 statFieldName)) == std::numeric_limits<unsigned long>::max()) {
827 if ((fieldId =
m_impl->m_inTuple->GetDescriptor().FindFieldId(
828 dynFieldName)) == std::numeric_limits<unsigned long>::max()) {
830 if (
m_impl->m_missingFields.size() <= auxid) {
831 m_impl->m_missingFields.resize(auxid + 1);
833 m_impl->m_missingFields[auxid] =
true;
836 return StatusCode::RECOVERABLE;
839 fieldName = std::move(dynFieldName);
843 const ROOT::RFieldDescriptor& fieldDesc =
844 m_impl->m_inTuple->GetDescriptor().GetFieldDescriptor(fieldId);
849 const bool containerField =
850 (primitiveField ? false : isContainerField(fieldDesc, auxid));
859 if ((containerField &&
861 !
r.isLinked(auxid)) ||
862 ((!containerField) &&
864 ::Error(
"xAOD::RAuxStore::setupInputData",
866 "differ for field: %s"),
868 return StatusCode::FAILURE;
872 const std::type_info* fieldType =
nullptr;
875 fieldType = (containerField ?
r.getVecType(auxid) :
r.getType(auxid));
878 TClass* clDummy = ::TClass::GetClass(fieldDesc.GetTypeName().c_str());
879 fieldType = (clDummy ? clDummy->GetTypeInfo()
883 ::Error(
"xAOD::RAuxStore::setupInputData",
884 XAOD_MESSAGE(
"Can't read/copy variable %s (%s)"), fieldName.c_str(),
885 fieldDesc.GetTypeName().c_str());
886 return StatusCode::RECOVERABLE;
891 ::TClass* fieldClass =
nullptr;
892 if (!primitiveField) {
894 fieldClass = ::TClass::GetClass(*fieldType,
true,
true);
896 fieldClass = ::TClass::GetClass(fieldTypeName);
899 ::Error(
"xAOD::RAuxStore::setupInputData",
900 XAOD_MESSAGE(
"No dictionary available for class \"%s\""),
901 fieldTypeName.Data());
902 return StatusCode::FAILURE;
908 m_data.m_vecs[auxid] =
r.makeVector(auxid, (
size_t)0, (
size_t)0);
909 if (!containerField) {
910 m_data.m_vecs[auxid]->resize(1);
913 strncmp(fieldClass->GetName(),
"SG::PackedContainer<", 20) == 0) {
914 std::unique_ptr<SG::IAuxTypeVector> packed =
915 m_data.m_vecs[auxid]->toPacked();
919 ::Error(
"xAOD::RAuxStore::setupInputData",
922 fieldName.c_str(),
static_cast<int>(auxid));
923 return StatusCode::FAILURE;
927 void* objectPtr = (containerField ?
m_data.m_vecs[auxid]->toVector()
928 :
m_data.m_vecs[auxid]->toPtr());
929 m_impl->m_fields[auxid] = std::make_unique<RFieldHandle>(
930 m_impl->m_inTuple->GetView<
void>(fieldName.c_str(), objectPtr), auxid,
931 m_data.m_prefix, objectPtr, fieldType);
938 m_data.m_auxIDs.insert(auxid);
943 const std::string auxname =
r.getName(auxid);
955 const std::string testname =
r.getName(i);
957 if (testname != auxname) {
962 ::Error(
"xAOD::RAuxStore::setupInputData",
968 m_impl->m_fields[i].reset();
979 return StatusCode::SUCCESS;
994 if (!
m_impl->m_outTuple) {
995 return StatusCode::SUCCESS;
1000 return StatusCode::SUCCESS;
1004 if (
m_data.m_vecs.size() <= auxid) {
1005 m_data.m_vecs.resize(auxid + 1);
1007 if (
m_impl->m_fieldsWritten.size() <= auxid) {
1008 m_impl->m_fieldsWritten.resize(auxid + 1);
1012 if (
m_impl->m_fieldsWritten[auxid]) {
1013 return StatusCode::SUCCESS;
1019 m_impl->m_fieldsWritten[auxid] =
true;
1026 if ((!
m_data.m_vecs[auxid]) &&
m_data.m_transientStore &&
1027 (
m_data.m_transientStore->getAuxIDs().test(auxid))) {
1030 const void* pptr =
m_data.m_transientStore->getData(auxid);
1032 ::Fatal(
"xAOD::RAuxStore::setupOutputData",
1034 return StatusCode::FAILURE;
1039 void* ptr =
m_data.m_vecs[auxid]->toPtr();
1041 ::Error(
"xAOD::RAuxStore::setupOutputData",
1044 return StatusCode::FAILURE;
1048 const std::type_info*
type = reg.getType(auxid);
1050 ::Error(
"xAOD::RAuxStore::setupOutputData",
1053 static_cast<int>(auxid));
1054 return StatusCode::FAILURE;
1059 ::Error(
"xAOD::RAuxStore::setupOutputData",
1060 XAOD_MESSAGE(
"No factory found for transient variable "
1062 static_cast<int>(auxid));
1063 return StatusCode::FAILURE;
1067 if (
m_data.m_isDecoration.size() <= auxid) {
1068 m_data.m_isDecoration.resize(auxid + 1);
1070 m_data.m_isDecoration[auxid] =
true;
1080 if ((
m_data.m_auxIDs.test(auxid)) && (!
m_data.m_vecs[auxid]) &&
1081 (!
m_impl->m_fields[auxid])) {
1088 ::Error(
"xAOD::RAuxStore::setupOutputData",
1089 XAOD_MESSAGE(
"Structure mode unknown for variable %s"),
1090 reg.getName(auxid).c_str());
1091 return StatusCode::FAILURE;
1095 if (!
m_data.m_vecs[auxid]) {
1096 m_data.m_vecs[auxid] = reg.makeVector(auxid, (
size_t)0, (
size_t)0);
1098 m_data.m_vecs[auxid]->resize(1);
1103 const std::string fieldName =
1104 std::format(
"{}{}",
m_data.m_dynPrefix, reg.getName(auxid));
1107 ? reg.getVecType(auxid)
1108 : reg.getType(auxid)));
1112 auto field = ROOT::RFieldBase::Create(fieldName, typeName).Unwrap();
1113 auto updater =
m_impl->m_outTuple->CreateModelUpdater();
1114 updater->BeginUpdate();
1115 updater->AddField(std::move(field));
1116 updater->CommitUpdate();
1120 m_data.m_auxIDs.insert(auxid);
1123 return StatusCode::SUCCESS;
1129 assert(
m_impl->m_fields.size() > auxid);
1130 assert(
m_impl->m_fields[auxid]);
1131 return m_impl->m_fields[auxid]->objectPtr();
1137 assert(
m_impl->m_fields.size() > auxid);
1138 assert(
m_impl->m_fields[auxid]);
1139 return m_impl->m_fields[auxid]->typeInfo();
An auxiliary data store that holds data internally.
Handle mappings between names and auxid_t.
Make an AuxVectorData object from either a raw vector or an aux store.
#define RETURN_CHECK(CONTEXT, EXP)
Helper macro for checking return codes in a compact form in the code.
Handle mappings between names and auxid_t.
const std::type_info * getType(SG::auxid_t auxid) const
Return the type of an aux data item.
SG::auxid_t getAuxID(const std::string &name, const std::string &clsname="", const Flags flags=Flags::None, const SG::auxid_t linkedVariable=SG::null_auxid)
Look up a name -> auxid_t mapping.
SG::auxid_t findAuxID(const std::string &name, const std::string &clsname="") const
Look up a name -> auxid_t mapping.
static bool isLinkedName(const std::string &name)
Test if a variable name corresponds to a linked variable.
std::string getName(SG::auxid_t auxid) const
Return the name of an aux data item.
static std::string linkedName(const std::string &name)
Given a variable name, return the name of the corresponding linked variable.
const std::type_info * getVecType(SG::auxid_t auxid) const
Return the type of the STL vector used to hold an aux data item.
static bool classNameHasLink(const std::string &className)
Test to see if a class name corresponds to a class with a linked variable.
static AuxTypeRegistry & instance()
Return the singleton registry instance.
const IAuxTypeVectorFactory * addFactory(const std::type_info &ti, const std::type_info &ti_alloc, std::unique_ptr< const IAuxTypeVectorFactory > factory)
Add a new type -> factory mapping.
Make an AuxVectorData object from either a raw array or an aux store.
Interface for factory objects that create vectors.
virtual const std::type_info * tiAlloc() const =0
Return the type_info of the vector allocator.
virtual void copy(SG::auxid_t auxid, AuxVectorData &dst, size_t dst_index, const AuxVectorData &src, size_t src_index, size_t n) const =0
Copy elements between vectors.
A set of aux data identifiers.
RAuxStore(std::string_view prefix="", bool topStore=true, EStructMode mode=EStructMode::kUndefinedStore)
Constructor.
StatusCode readFrom(ROOT::RNTupleReader &reader)
Connect the object to an input RNTuple.
virtual const std::type_info * getInputType(SG::auxid_t auxid) const override
Get the type of an input object, for getIOType()
StatusCode writeTo(ROOT::RNTupleWriter &writer)
Add the variables of the store to an output RNTuple.
StatusCode getEntry(std::int64_t entry, int getall=0)
Get entry from the input RNTuple.
virtual StatusCode setupInputData(SG::auxid_t auxid) override
Connect a variable to the input.
virtual StatusCode getEntryFor(SG::auxid_t auxid) override
Load a single variable from the input.
std::unique_ptr< impl > m_impl
Pointer to the internal object.
virtual const void * getInputObject(SG::auxid_t auxid) const override
Get a pointer to an input object, as it is in memory, for getIOData()
virtual bool hasEntryFor(SG::auxid_t auxid) const override
Check if a given variable is available from the input.
virtual void setPrefix(std::string_view prefix) override
Set the object name prefix.
StatusCode commitTo(ROOT::REntry &entry)
Commit a new entry to the output RNTuple.
virtual StatusCode setupOutputData(SG::auxid_t auxid) override
Connect a variable to the output.
virtual bool hasOutput() const override
Check if an output is being written by the object.
virtual ~RAuxStore()
Destructor.
virtual void reset() override
Tell the object that all branches will need to be re-read.
virtual const void * getIOData(SG::auxid_t auxid) const override
Get a pointer to the data being stored for one aux data item.
const std::string & prefix() const
Get the currently configured object name prefix.
bool isAuxIDSelected(SG::auxid_t auxid) const
Check if an auxiliary variable is selected for ouput writing.
virtual SG::auxid_set_t getSelectedAuxIDs() const override
Get the IDs of the selected aux variables.
AthContainers_detail::mutex mutex_t
Mutex type for multithread synchronization.
EStructMode
"Structural" modes of the object
@ kUndefinedStore
The structure mode is not defined.
@ kObjectStore
The object describes a single object.
@ kContainerStore
The object describes an entire container.
AuxStoreBase(bool topStore=true, EStructMode mode=EStructMode::kUndefinedStore)
Constructor.
Members m_data
Member variables of the base class.
AthContainers_detail::lock_guard< mutex_t > guard_t
Guard type for multithreaded synchronisation.
constexpr std::enable_if_t< is_bitmask_v< E >, E & > reset(E &lhs, E rhs)
Convenience function to clear bits in a class enum bitmask.
::StatusCode StatusCode
StatusCode definition for legacy code.
AuxVarFlags
Additional flags to qualify an auxiliary variable.
@ Linked
Mark that this variable is linked to another one.
std::string normalizedTypeinfoName(const std::type_info &info)
Convert a type_info to a normalized string representation (matching the names used in the root dictio...
static const auxid_t null_auxid
To signal no aux data item.
size_t auxid_t
Identifier for a particular aux data item.
cl
print [x.__class__ for x in toList(dqregion.getSubRegions()) ]
void swap(ElementLinkVector< DOBJ > &lhs, ElementLinkVector< DOBJ > &rhs)
const std::type_info & getTypeInfo(EDataType type)
This function is used when reading a primitive branch from an input file without the user explicitly ...
bool isPrimitiveType(std::string_view typeName)
Check if the type name describes a primitive type.
std::string getTypeName(const std::type_info &ti)
This function is necessary in order to create type names that ROOT can understand.
std::string dynFieldPrefix(const std::string &key)
This function is used to figure out what to name dynamic auxiliary field coming from a container call...
TClass * lookupVectorType(TClass &cl)
Internal function used by xAOD::TAuxStore and xAOD::RAuxStore.
bool isRegisteredType(SG::auxid_t auxid)
Check if the auxiliary variable has a registered type.
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
bool m_inputScanned
"Scan status" of the input RNTuple
std::vector< bool > m_fieldsWritten
"Write status" of the different variables
::Long64_t m_entry
The entry to load from the ntuple.
std::vector< bool > m_missingFields
Mark fields we've found to be missing.
Members & m_data
Variables coming from AuxStoreBase.
ROOT::RNTupleWriter * m_outTuple
The ntuple being written to.
std::vector< std::unique_ptr< RFieldHandle > > m_fields
Fields containing the various auxiliary variables.
StatusCode scanInputTuple()
Scans the input ntuple for auxiliary data fields and sets up the necessary structures to access them.
ROOT::RNTupleReader * m_inTuple
The ntuple being read from.
const std::type_info * auxFieldType(const ROOT::RFieldBase &field, std::string *expectedClassName=nullptr)
This function retrieves the type information for a given auxiliary field.
StatusCode setupAuxField(const ROOT::RFieldBase &field, std::string_view auxName)
This function sets up an auxiliary field by determining its type and attempting to register it with t...
mutex_t m_mutex
Mutex object used for multithreaded synchronisation.
Struct collecting all member variables of this base class.