29 if (TClass*
cl = (TClass*)gROOT->GetListOfClasses()->FindObject(cname.c_str())) {
30 if (
cl->IsLoaded() &&
cl->HasDictionary())
return cl;
44 TClass*
cl = TClass::GetClass (cname.c_str());
45 if (
cl->HasDictionary())
65 const std::string&
name,
66 const std::string& elementTypeName,
67 const std::string& branchTypeName,
79 auxid =
r.getAuxID (ti,
name,
"",
flags, linked_auxid);
80 if (auxid != SG::null_auxid)
return auxid;
86 std::string tn = elementTypeName;
87 if (tn.starts_with(
"std::vector<"))
89 std::string fac_class_name =
"SG::AuxTypeVectorFactory<" +
90 tn +
",allocator<" + tn;
91 if (fac_class_name[fac_class_name.size()-1] ==
'>')
92 fac_class_name +=
' ';
93 fac_class_name +=
"> >";
99 int offs = fac_class->GetBaseClassOffset (base_class);
101 void* fac_vp = fac_class->New();
104 const std::type_info* tiAlloc = fac->
tiAlloc();
105 r.addFactory (ti, *tiAlloc, std::unique_ptr<SG::IAuxTypeVectorFactory> (fac));
112 if (auxid == SG::null_auxid) {
113 if (linked_auxid != SG::null_auxid) {
115 msg <<
"dynamic ROOT vector factory not implemented for linked types: "
116 <<
name <<
" " << branchTypeName <<
"\n";
117 return SG::null_auxid;
120 std::string vec_name = branchTypeName;
122 vec_name =
"std::vector<" + branchTypeName;
123 if (vec_name[vec_name.size()-1] ==
'>')
127 TClass* vec_class = TClass::GetClass (vec_name.c_str());
130 auto facp = std::make_unique<SG::RootAuxVectorFactory> (vec_class);
131 std::string tiAllocName = facp->tiAllocName();
132 (void)
r.addFactory (ti, tiAllocName, std::move (facp));
133 auxid =
r.getAuxID(tiAllocName, ti,
name,
"",
flags);