109#define RTLD_DEFAULT ((void *)::GetModuleHandle(NULL))
110#define dlsym(library, function_name) ::GetProcAddress((HMODULE)library, function_name)
127using std::multimap, std::make_pair, std::string;
136 static constexpr const char kUndeterminedClassInfoName[] =
"<NOT YET DETERMINED FROM fClassInfo>";
138 class TMmallocDescTemp {
142 TMmallocDescTemp(
void *
value =
nullptr) :
163 TNameMapNode(
const char *typedf,
const char *orig) :
176 const static bool foundSymbol = dlsym(RTLD_DEFAULT,
"usedToIdentifyRootClingByDlSym");
199 auto strLen =
name ? strlen(
name) : 0;
200 if (strLen == 0)
return;
202 const char* endCharPtr = strchr(
name,
'<');
203 endCharPtr = !endCharPtr ? &
name[strLen] : endCharPtr;
205 const char* beginCharPtr = endCharPtr;
206 while (beginCharPtr!=
name){
207 if (*beginCharPtr==
':'){
213 beginCharPtr = beginCharPtr!=endCharPtr ? beginCharPtr :
name;
214 std::string s(beginCharPtr, endCharPtr);
216 printf(
"TDeclNameRegistry::AddQualifiedName Adding key %s for class/namespace %s\n", s.c_str(),
name);
238 printf(
"TDeclNameRegistry Destructor. List of %lu names:\n",
241 printf(
" - %s\n", key.c_str());
306 std::pair<RepoCont_t::iterator, Bool_t> tmp =
fObjectVersionRepository.insert(RepoCont_t::value_type>(location, version));
308 Warning(where,
"Reregistering an object of class '%s' version %d at address %p",
what->GetName(), version, p);
312 Warning(where,
"Failed to reregister an object of class '%s' version %d at address %p",
what->GetName(), version, location);
325 RepoCont_t::iterator tmp = cur++;
326 if ((tmp->first == location) && (tmp->second ==
what->GetClassVersion())) {
342 size_t objsize =
what->Size();
343 long delta = (
char*)newadd - (
char*)oldadd;
347 RepoCont_t::iterator tmp = cur++;
348 if (oldadd <= tmp->first && tmp->first < ( ((
char*)oldadd) + objsize) ) {
364#define R__USE_STD_MAP
366#if defined R__USE_STD_MAP
370 typedef std::map<std::string,TClass*>
IdMap_t;
393 IdMap_t::const_iterator iter =
fMap.find(key);
395 if (iter !=
fMap.end()) cl = iter->second;
407#ifdef R__COMPLETE_MEM_TERMINATION
416 void Add(
const char *key, TClass *&obj) {
417 TObjString *realkey =
new TObjString(key);
418 fMap.Add(realkey, obj);
420 TClass*
Find(
const char *key)
const {
421 const TPair *
a = (
const TPair *)fMap.FindObject(key);
422 if (
a)
return (TClass*)
a->Value();
425 void Remove(
const char *key) {
426 TObjString realkey(key);
427 TObject *actual = fMap.Remove(&realkey);
450 std::pair<const key_type, mapped_type>
pair = make_pair(key, obj);
455 return fMap.count(key);
460 return fMap.equal_range(key);
471#ifdef R__COMPLETE_MEM_TERMINATION
473 return &gIdMapObject;
482#ifdef R__COMPLETE_MEM_TERMINATION
484 return &gDeclIdMapObject;
499 gROOT->GetListOfClasses()->Add(cl);
513 if (!cl || !
id)
return;
525 gROOT->GetListOfClasses()->Remove(oldcl);
560 void Inspect(
TClass *cl,
const char *parent,
const char *
name,
const void *addr,
Bool_t isTransient)
override;
576 const Int_t kvalue = 30;
578 const Int_t ktitle = 50;
580 const Int_t ktitle = 42;
582 const Int_t kline = 1024;
585 UInt_t *cdatime =
nullptr;
590 const char *memberName;
591 const char *memberFullTypeName;
592 const char *memberTitle;
598 if (member->GetDataType()) {
599 memberDataType = (
EDataType)member->GetDataType()->GetType();
601 memberName = member->GetName();
602 memberFullTypeName = member->GetFullTypeName();
603 memberTitle = member->GetTitle();
604 isapointer = member->IsaPointer();
605 isbasic = member->IsBasic();
607 isarray = member->GetArrayDim();
613 const char *
cursor = mname;
617 if ( pos !=
kNPOS ) {
621 if (!element)
return;
626 memberName = element->
GetName();
629 membertype =
gROOT->GetType(memberFullTypeName);
631 isbasic = membertype !=
nullptr;
639 if (strcmp(memberName,
"fDatime") == 0 && memberDataType ==
kUInt_t) {
643 if (strcmp(memberName,
"fBits") == 0 && memberDataType ==
kUInt_t) {
648 static TClassRef stdClass(
"std::string");
649 Bool_t isStdString = (dataClass == stdClass);
652 for (
i = 0;
i < kline;
i++)
line[
i] =
' ';
658 char *pointer = (
char*)add;
659 char **ppointer = (
char**)(pointer);
662 char **p3pointer = (
char**)(*ppointer);
667 snprintf(&
line[kvalue],kline-kvalue,
"->%zx ", (
size_t)p3pointer);
669 }
else if (membertype) {
671 i = strlen(*ppointer);
672 if (kvalue+
i > kline)
i=kline-1-kvalue;
674 for (
Int_t j = 0; j <
i; j++) {
675 if (!std::isprint((*ppointer)[j])) {
681 strncpy(
line + kvalue, *ppointer,
i);
689 }
else if (!strcmp(memberFullTypeName,
"char*") ||
690 !strcmp(memberFullTypeName,
"const char*")) {
691 i = strlen(*ppointer);
692 if (kvalue+
i >= kline)
i=kline-1-kvalue;
694 for (
Int_t j = 0; j <
i; j++) {
695 if (!std::isprint((*ppointer)[j])) {
701 strncpy(
line + kvalue, *ppointer, std::min(
i, kline - kvalue));
708 snprintf(&
line[kvalue],kline-kvalue,
"->%zx ", (
size_t)p3pointer);
711 }
else if (membertype) {
713 cdatime = (
UInt_t*)pointer;
715 snprintf(&
line[kvalue],kline-kvalue,
"%d/%d",cdate,ctime);
723 std::string *str = (std::string*)pointer;
725 }
else if (isTString) {
730 snprintf(&
line[kvalue],kline-kvalue,
"->%zx ", (
size_t)pointer);
735 if (isdate ==
kFALSE && strcmp(memberFullTypeName,
"char*") && strcmp(memberFullTypeName,
"const char*")) {
737 assert(250 > ktitle);
738 strlcpy(&
line[ktitle],memberTitle,250-ktitle+1);
742 strncat(
line,
" ...", kline-strlen(
line)-1);
764 void Inspect(
TClass *cl,
const char *parent,
const char *
name,
const void *addr,
Bool_t isTransient)
override;
783 isTransientMember =
kTRUE;
882 void* addrForRecursion =
nullptr;
884 addrForRecursion =
const_cast<void*
>(add);
913 void Inspect(
TClass *cl,
const char *parent,
const char *
name,
const void *addr,
Bool_t isTransient)
override;
921 const void *addr,
Bool_t )
923 if(tit && strchr(tit,
'.'))
return ;
931 int ln = strcspn(
name,
"[ ");
935 if (!classInfo)
return;
942 while (
gCling->DataMemberInfo_Next(
m)) {
943 mname =
gCling->DataMemberInfo_Name(
m);
945 if ((found = (iname==mname)))
break;
957 if (mname ==
"G__virtualinfo")
return;
959 int size =
sizeof(
void*);
963 for (
int dim = 0; dim <
gCling->DataMemberInfo_ArrayDim(
m); dim++) nmax *=
gCling->DataMemberInfo_MaxIndex(
m,dim);
976 gCling->DataMemberInfo_Delete(
m);
979 for(
int i=0;
i<nmax;
i++) {
981 char *ptr = (
char*)addr +
i*
size;
996 bwname = actualClass->
GetName();
1003 strcmp(bwname.
Data(),actualClass->
GetName())==0) {
1005 int l = strcspn(bwname.
Data(),
"[ ");
1006 if (
l<bwname.
Length() && bwname[
l]==
'[') {
1007 char cbuf[13];
snprintf(cbuf,13,
"[%02d]",
i);
1010 bwname = (
const char*)ts;
1014 if (proxy==
nullptr) {
1021 if (valueCl==
nullptr) {
1027 TClass *actualCl =
nullptr;
1029 int sz = proxy->
Size();
1031 char fmt[] = {
"#%09d"};
1032 fmt[3] =
'0'+(
int)log10(
double(sz))+1;
1034 for (
int ii=0;ii<sz;ii++) {
1035 void *p = proxy->
At(ii);
1089 TMmallocDescTemp setreset;
1125 ::Fatal(
"TClass::TClass",
"ROOT system not initialized");
1128 TMmallocDescTemp setreset;
1135 ::Fatal(
"TClass::TClass",
"gInterpreter not initialized");
1139 ::Warning(
"TClass::TClass",
"no dictionary for class %s is available",
name);
1171 Init(
name, cversion,
nullptr,
nullptr,
nullptr,
nullptr, -1, -1,
nullptr, silent);
1208 "A TClass entry cannot be initialized in a state different from kForwardDeclared or kEmulated.");
1209 Init(
name, cversion,
nullptr,
nullptr,
nullptr,
nullptr, -1, -1,
nullptr, silent);
1247 ::Fatal(
"TClass::TClass",
"ROOT system not initialized");
1253 ::Fatal(
"TClass::TClass",
"gInterpreter not initialized");
1255 if (!classInfo || !
gInterpreter->ClassInfo_IsValid(classInfo)) {
1262 Init(
fName, cversion,
nullptr,
nullptr, dfil, ifil, dl, il, classInfo, silent);
1296 Init(
name,cversion,
nullptr,
nullptr, dfil, ifil, dl, il,
nullptr, silent);
1306 const char *dfil,
const char *ifil,
Int_t dl,
Int_t il,
1329 Init(
name, cversion, &info, isa, dfil, ifil, dl, il,
nullptr, silent);
1347 info->
Clear(
"build");
1372 const char *dfil,
const char *ifil,
Int_t dl,
Int_t il,
1373 ClassInfo_t *givenInfo,
1377 ::Fatal(
"TClass::TClass",
"ROOT system not initialized");
1379 ::Error(
"TClass::Init",
"The name parameter is invalid (null or empty)");
1420 TClass **persistentRef =
nullptr;
1438 info->
Clear(
"build");
1456 (*fMethod).fClass =
this;
1468 ::Fatal(
"TClass::Init",
"gInterpreter not initialized");
1471 bool invalid = !
gInterpreter->ClassInfo_IsValid(givenInfo);
1472 bool notloaded = !
gInterpreter->ClassInfo_IsLoaded(givenInfo);
1473 auto property =
gInterpreter->ClassInfo_Property(givenInfo);
1515 proto->FillTClass(
this);
1541 ::Error(
"TClass::Init",
"no interpreter information for class %s is available even though it has a TClass "
1542 "initialization routine.",
1548 ::Warning(
"TClass::Init",
"no dictionary for class %s is available",
fName.Data());
1560 if (!givenInfo && strchr (
name,
'<')) {
1572 if (resolvedThis !=
name) {
1596 if (resolvedThis !=
fName) {
1597 oldcl = (
TClass*)
gROOT->GetListOfClasses()->FindObject(resolvedThis);
1598 if (oldcl && oldcl !=
this) {
1604 while ( TNameMapNode* htmp =
static_cast<TNameMapNode*
> (next()) ) {
1605 if (resolvedThis != htmp->String())
continue;
1606 oldcl = (
TClass*)
gROOT->GetListOfClasses()->FindObject(htmp->fOrigName);
1607 if (oldcl && oldcl !=
this) {
1625 if (persistentRef) {
1632 if ( isStl || !strncmp(
GetName(),
"stdext::hash_",13) || !strncmp(
GetName(),
"__gnu_cxx::hash_",16) ) {
1643 }
else if (!silent) {
1644 Warning(
"Init",
"Collection proxy for %s was not properly initialized!",
GetName());
1669 while ( TNameMapNode* htmp =
static_cast<TNameMapNode*
> (next()) ) {
1670 if (resolvedThis == htmp->String() && htmp->fOrigName ==
GetName()) {
1696 (*fUsingData).Delete();
1708 (*fMethod).Delete();
1741 std::map<std::string, TObjArray*>::iterator it;
1742 std::map<std::string, TObjArray*>::iterator end = (*fConversionStreamerInfo).end();
1743 for( it = (*fConversionStreamerInfo).begin(); it != end; ++it ) {
1753 Int_t ReadRulesContent(FILE *
f)
1765 while ((
c = fgetc(
f)) != EOF) {
1771 if (rule.Length() > 0) {
1823 static const char *suffix =
"class.rules";
1829 FILE *
f = fopen(sname,
"r");
1831 res = ReadRulesContent(
f);
1834 ::Error(
"TClass::ReadRules()",
"Cannot find rules file %s", sname.
Data());
1848 ::Error(
"TClass::ReadRules",
"no file name specified");
1857 Int_t count = ReadRulesContent(
f);
1910 ::Warning(
"TClass::AddRule",
"The rule for class: \"%s\": version, \"%s\" and data members: \"%s\" has been skipped because it conflicts with one of the other rules (%s).",
1972 obj->ShowMembers(insp);
1993 }
else if (actual !=
this) {
1994 return actual->
Browse(obj,
b);
2043 isTransient =
kTRUE;
2048 TMmallocDescTemp setreset;
2059 static TClassRef clRefString(
"std::string");
2060 if (clRefString ==
this) {
2070 Error(
"BuildRealData",
"Inspection for %s not supported!",
GetName());
2082 if ( isTransient ) {
2090 Error(
"BuildRealData",
"Cannot find any ShowMembers function for %s!",
GetName());
2105 c->BuildRealData(
nullptr, isTransient);
2125 Error(
"BuildEmulatedRealData",
"Missing StreamerInfo for %s",
GetName());
2191 TMmallocDescTemp setreset;
2218 if (strcmp(
GetName(),
"string") == 0) {
2226 gInterpreter->InspectMembers(insp, obj,
this, isTransient);
2230 sinfo->CallShowMembers(obj, insp, isTransient);
2245 return gInterpreter->InspectMembers(insp, obj,
this, isTransient);
2308 }
else if (!
c->CanSplitBaseAllow()) {
2352 static TClassRef stdStringClass(
"std::string");
2409 if (new_name ==
nullptr || new_name[0]==
'\0' ||
fName == new_name) {
2410 Error(
"Clone",
"The name of the class must be changed when cloning a TClass object.");
2440 copy->
fName = new_name;
2499 gROOT->ProcessLine(
"new TCanvas(\"R__class\",\"class\",20,20,1000,750);");
2547 if (
sizeof(
this) == 4)
2550 Printf(
"==> Dumping object at: 0x%016lx, name=%s, class=%s\n",prObj,tobj->
GetName(),
GetName());
2553 if (
sizeof(
this) == 4)
2554 Printf(
"==> Dumping object at: 0x%08lx, class=%s\n",prObj,
GetName());
2556 Printf(
"==> Dumping object at: 0x%016lx, class=%s\n",prObj,
GetName());
2561 Info(
"Dump",
"No ShowMembers function, dumping disabled");
2571 static const UInt_t maxsize = 255;
2572 static char name[maxsize+2];
2576 for (
UInt_t i = 0;
i < nch && icur < maxsize; ++
i, ++icur) {
2624 return realTObject->
IsA();
2659 if (strcmp(
GetName(), classname) == 0)
return this;
2668 else return nullptr;
2678 if (cl ==
this)
return this;
2690 if (cl ==
c)
return c;
2691 c1 =
c->GetBaseClass(cl);
2709 if (cl ==
this)
return 0;
2711 if (!
fBase.load()) {
2718 if (!sinfo)
return -1;
2730 if (!baseclass)
return -1;
2732 if (subOffset == -2)
return -2;
2733 if (subOffset != -1)
return offset+subOffset;
2738 if (!baseclass)
return -1;
2740 if (subOffset == -2)
return -2;
2741 if (subOffset != -1)
return offset+subOffset;
2745 Error(
"GetBaseClassOffsetRecurse",
"Unexpected element type for base class: %s\n",element->
IsA()->
GetName());
2757 if (
fBase.load() ==
nullptr)
2760 lnk =
fBase.load()->FirstLink();
2776 off =
c->GetBaseClassOffsetRecurse(cl);
2777 if (off == -2)
return -2;
2796 if (
this == toBase)
return 0;
2812 if(derived && base) {
2814 return gCling->ClassInfo_GetBaseOffset(derived, base, address, isDerivedObject);
2834 if (dm)
return this;
2842 TClass *cdm =
c->GetBaseDataMember(datamember);
2843 if (cdm)
return cdm;
2854 struct TClassLocalStorage {
2855 TClassLocalStorage() : fCollectionProxy(nullptr), fStreamer(nullptr) {};
2857 TVirtualCollectionProxy *fCollectionProxy;
2858 TClassStreamer *fStreamer;
2860 static TClassLocalStorage *GetStorage(
const TClass *cl)
2866 if (*thread_ptr==
nullptr) *thread_ptr =
new TExMap();
2867 TExMap *lmap = (TExMap*)(*thread_ptr);
2873 local = (
ULongptr_t)
new TClassLocalStorage();
2876 return (TClassLocalStorage*)local;
2904 TClassLocalStorage *local = TClassLocalStorage::GetStorage(
this);
2906 if (local->fCollectionProxy==
nullptr) local->fCollectionProxy =
fCollectionProxy->Generate();
2907 return local->fCollectionProxy;
2918 TClassLocalStorage *local = TClassLocalStorage::GetStorage(
this);
2920 if (local->fStreamer==
nullptr) {
2921 local->fStreamer =
fStreamer->Generate();
2922 const std::type_info &orig = (
typeid(*fStreamer) );
2923 if (!local->fStreamer) {
2924 Warning(
"GetStreamer",
"For %s, the TClassStreamer (%s) passed's call to Generate failed!",
GetName(),orig.name());
2926 const std::type_info © = (
typeid(*local->fStreamer) );
2927 if (strcmp(orig.name(),copy.name())!=0) {
2928 Warning(
"GetStreamer",
"For %s, the TClassStreamer passed does not properly implement the Generate method (%s vs %s)\n",
GetName(),orig.name(),copy.name());
2932 return local->fStreamer;
2976 if (!
name || !
name[0])
return nullptr;
2978 if (strstr(
name,
"(anonymous)"))
return nullptr;
2979 if (strstr(
name,
"(unnamed)"))
return nullptr;
2980 if (strncmp(
name,
"class ",6)==0)
name += 6;
2981 if (strncmp(
name,
"struct ",7)==0)
name += 7;
2983 if (!
gROOT->GetListOfClasses())
return nullptr;
3042 TClass *loadedcl = (dict)();
3055 std::string normalizedName;
3064 if (
type->GetType() > 0)
3068 normalizedName =
type->GetTypeName();
3069 nameChanged =
kTRUE;
3077 if (normalizedName !=
name) {
3078 cl = (
TClass*)
gROOT->GetListOfClasses()->FindObject(normalizedName.c_str());
3087 nameChanged =
kTRUE;
3090 normalizedName = cl->
GetName();
3105 auto loadClass = [](
const char *requestedname) ->
TClass* {
3108 TClass *loadedcl = (dict)();
3119 if(
TClass *loadedcl = loadClass(normalizedName.c_str()))
3124 if (
TClass *loadedcl = loadClass(normalizedName.c_str()))
3136 std::string normalizedNameAfterAutoLoad;
3138 nameChanged = normalizedNameAfterAutoLoad != normalizedName;
3139 normalizedName = normalizedNameAfterAutoLoad;
3153 if (!ispair && !ispairbase) {
3154 if (
TDataType* theDataType =
gROOT->GetType(normalizedName.c_str())){
3156 auto underlyingTypeName = theDataType->GetTypeName();
3173 if (hint_pair_offset && hint_pair_size) {
3181 static const size_t slen = strlen(
"pair");
3182 static const char *associativeContainer[] = {
"map",
"unordered_map",
"multimap",
3183 "unordered_multimap",
"set",
"unordered_set",
"multiset",
"unordered_multiset" };
3184 for(
auto contname : associativeContainer) {
3185 std::string collname = contname;
3186 collname.append( normalizedName.c_str() + slen );
3193 cl = p->GetValueClass();
3206 std::string::size_type posLess = normalizedName.find(
'<');
3207 if (posLess != std::string::npos) {
3208 gCling->AutoParse(normalizedName.substr(0, posLess).c_str());
3214 printf(
"TClass::GetClass: Header Parsing - The representation of %s was not found in the type system. A lookup in the interpreter is about to be tried: this can cause parsing. This can be avoided selecting %s in the linkdef/selection file.\n",normalizedName.c_str(), normalizedName.c_str());
3216 if (normalizedName.length()) {
3226 auto ci =
gInterpreter->ClassInfo_Factory(normalizedName.c_str());
3228 auto method =
gInterpreter->MethodInfo_Factory(funcDecl);
3234 funcPtr(
nullptr, 0,
nullptr, &res);
3246 std::string alternative;
3247 gInterpreter->GetInterpreterTypeName(normalizedName.c_str(), alternative,
kTRUE);
3248 if (alternative.empty())
3250 const char *altname = alternative.c_str();
3251 if (strncmp(altname,
"std::", 5) == 0) {
3256 if (altname != normalizedName && strcmp(altname,
name) != 0) {
3283 if (!
gROOT->GetListOfClasses())
3291 if (cl && cl->
IsLoaded())
return cl;
3317 if (!load)
return nullptr;
3327 TIter next(
gROOT->GetListOfClassGenerators());
3338 int autoload_old =
gCling->SetClassAutoLoading(1);
3339 if (!autoload_old) {
3341 gCling->SetClassAutoLoading(0);
3346 cl =
GetClass(typeinfo, load, hint_pair_offset, hint_pair_size);
3352 if (hint_pair_offset) {
3357 free(demangled_name);
3380 if (!info || !
gCling->ClassInfo_IsValid(info))
return nullptr;
3381 if (!
gROOT->GetListOfClasses())
return nullptr;
3402 if (!load)
return nullptr;
3404 TClass *loadedcl =
nullptr;
3405 if (cl) loadedcl =
gROOT->LoadClass(cl->
GetName(),silent);
3406 else loadedcl =
gROOT->LoadClass(
name,silent);
3408 if (loadedcl)
return loadedcl;
3433 if (!
gROOT->GetListOfClasses())
return 0;
3438 if (iter.first == iter.second)
return false;
3439 std::vector<TClass*>::iterator vectIt = classes.begin();
3441 vectIt = classes.insert(vectIt, it->second);
3469 || datamember ==
nullptr)
return nullptr;
3472 const char *start_name = datamember;
3473 while (*start_name ==
'*') ++start_name;
3478 if (
const char *s = strchr(start_name,
'[')){
3508 if (strchr(
name,
'[')==
nullptr) {
3550 std::string givenName(
name);
3553 std::string::size_type firstBracket = givenName.find_first_of(
"[");
3554 if (firstBracket != std::string::npos) {
3556 std::string nameNoDim(givenName.substr(0, firstBracket));
3560 std::string objName(obj->
GetName());
3561 std::string::size_type pos = objName.find_first_of(
"[");
3563 if (pos != std::string::npos) {
3565 if (objName == nameNoDim) {
3574 std::ostringstream ptrname;
3575 ptrname <<
"*" << givenName;
3582 std::string::size_type firstDot = givenName.find_first_of(
".");
3583 if (firstDot == std::string::npos) {
3594 std::string::size_type lastDot = givenName.find_last_of(
".");
3595 std::ostringstream starname;
3596 starname << givenName.substr(0, lastDot) <<
".*" << givenName.substr(lastDot + 1);
3612 std::string::size_type bracket = starname.str().find_first_of(
"[");
3613 if (bracket != std::string::npos) {
3622 std::string firstDotName(givenName.substr(firstDot + 1));
3665 if (!
fBase.load()) {
3686 Fatal(
"GetListOfBases",
"gInterpreter not initialized");
3689 if (!
fBase.load()) {
3715 auto temp =
fEnums.load();
3717 if (requestListLoading) {
3732 if (!requestListLoading) {
3787 if (!(*data).IsLoaded())
3790 }
else if (load) (*data).Load();
3804 }
else if (!load &&
fData)
3845 if (
gDebug>0)
Info(
"GetListOfMethods",
"Header Parsing - Asking for all the methods of class %s: this can involve parsing.",
GetName());
3878 if (
gDebug>0)
Info(
"GetListOfAllPublicMethods",
"Header Parsing - Asking for all the methods of class %s: this can involve parsing.",
GetName());
3908 while ((baseClass = (
TBaseClass *) nextBase())) {
3916 while ((method = (
TMethod*)next())) {
3920 list->AddFirst(method);
3922 if (
m &&
m->GetNargs() == method->
GetNargs())
3947 return cl->IsLoaded();
3975 TIter nextMemb(ldm);
3986 TClass* dmTClass =
nullptr;
4006 for (
int i = 0;
i < 2;
i++) {
4022 if (
this == sCIString)
return;
4034 auto checkDicts = [&](
const string &clName){
4041 if (cl && !cl->HasDictionary()) {
4042 cl->GetMissingDictionariesWithRecursionCheck(
result, visited, recurse);
4046 const auto &elements = splitType.
fElements;
4047 const auto &templName = elements[0];
4050 if (templName ==
"pair") {
4058 if (templName ==
"unique_ptr" || templName ==
"array") {
4059 checkDicts(elements[1]);
4066 if (templName ==
"tuple") {
4069 const auto nTemplArgs = elements.size() - 1;
4071 for (
auto iTemplArg = 1U; iTemplArg < nTemplArgs; ++iTemplArg) {
4072 checkDicts(elements[iTemplArg]);
4118 if (
result.FindObject(
this))
return;
4121 if (
this == sCIString)
return;
4130 if (strncmp(
fName,
"unique_ptr<", 11) == 0 || strncmp(
fName,
"array<", 6) == 0 || strncmp(
fName,
"tuple<", 6) == 0) {
4183 while ((acl = (
TClass*)nextClass())) {
4184 if (acl == newcl)
continue;
4189 info->
Update(
this, newcl);
4201 Warning(
"ResetClassInfo(Long_t tagnum)",
"Call to deprecated interface (does nothing)");
4250 (*fUsingData).Unload();
4254 (*fMethod).Unload();
4288 if (options==
nullptr || options[0]==0)
return;
4290 if (strstr(options,
"streamerinfo")!=
nullptr) {
4294 std::map<std::string, TObjArray*>::iterator it;
4295 std::map<std::string, TObjArray*>::iterator end = (*fConversionStreamerInfo).end();
4296 for( it = (*fConversionStreamerInfo).begin(); it != end; ++it ) {
4297 it->second->ls(options);
4323 TClass *classPtr =
nullptr;
4324 TIter next(methodList);
4326 while ((method = (
TMethod*) next())) {
4328 if (classPtr != method->
GetClass()) {
4336 TIter nextarg(margsList);
4337 while ((methodArg = (
TMethodArg*)nextarg())) {
4387 if(
fMethod.compare_exchange_strong(expected, temp.get()) ) {
4423 m =
c->GetMethodAllAny(method);
4445 Fatal(
"GetMethod",
"gInterpreter not initialized");
4451 if (!decl)
return nullptr;
4458 "\nDid not find matching TMethod <%s> with \"%s\" %sfor %s",
4459 method,params,objectIsConst ?
"const " :
"",
GetName());
4469 return static_cast<TMethod *
>(method);
4472 if (
auto base =
static_cast<TBaseClass *
>(item)->GetClassPointer())
4473 if (
TFunction* method = base->FindClassOrBaseMethodWithId(declId))
4474 return static_cast<TMethod *
>(method);
4491 Fatal(
"GetMethodWithPrototype",
"gInterpreter not initialized");
4495 objectIsConst,
mode);
4497 if (!decl)
return nullptr;
4500 Error(
"GetMethodWithPrototype",
4501 "\nDid not find matching TMethod <%s> with \"%s\" %sfor %s",
4502 method,
proto,objectIsConst ?
"const " :
"",
GetName());
4517 if (faddr == (
Longptr_t)
m->InterfaceMethod())
4536 Fatal(
"GetClassMethod",
"gInterpreter not initialized");
4542 if (!decl)
return nullptr;
4562 Fatal(
"GetClassMethodWithPrototype",
"gInterpreter not initialized");
4569 if (!decl)
return nullptr;
4667 if ((version < -1) || (version >= (
fStreamerInfo->GetSize()-1))) {
4668 Error(
"GetStreamerInfo",
"class: %s, attempting to access a wrong version: %d",
GetName(), version);
4687 TMmallocDescTemp setreset;
4696 sinfo->
Build(silent);
4741 newname +=
"@@emulated";
4766 for (
Int_t i = -1; sinfo ==
nullptr &&
i < ninfos; ++
i)
4779 Error(
"GetStreamerInfoAbstractEmulated",
"could not create TVirtualStreamerInfo");
4804 newname +=
"@@emulated";
4819 if (!sinfo && (checksum !=
fCheckSum)) {
4829 for (
Int_t i = -1; sinfo ==
nullptr &&
i < ninfos; ++
i)
4842 Error(
"GetStreamerInfoAbstractEmulated",
"could not create TVirtualStreamerInfo");
4889 Error(
"IgnoreTObjectStreamer",
"Must be called before the creation of StreamerInfo");
4915 if (cl ==
this)
return kTRUE;
4925 if (!clbase)
return kFALSE;
4944 if (cl ==
this)
return obj;
5007 auto obj =
NewObject(defConstructor, quiet);
5008 if (obj.GetPtr() && obj.GetAllocator()) {
5012 return obj.GetPtr();
5034 Error(
"New",
"cannot create object of class %s",
GetName());
5051 Error(
"New",
"cannot create object of class %s",
GetName());
5063 Error(
"New",
"cannot create object of class %s",
GetName());
5092 p = { sinfo->
New(), sinfo};
5102 Error(
"New",
"Failed to construct class '%s' using streamer info",
GetName());
5107 Fatal(
"New",
"This cannot happen!");
5120 auto obj =
NewObject(arena, defConstructor);
5121 if (obj.GetPtr() && obj.GetAllocator()) {
5125 return obj.GetPtr();
5147 Error(
"New with placement",
"cannot create object of class %s version %d at address %p",
GetName(),
fClassVersion, arena);
5163 Error(
"New with placement",
"cannot create object of class %s version %d at address %p",
GetName(),
fClassVersion, arena);
5192 Error(
"New with placement",
"Cannot construct class '%s' version %d at address %p, no streamer info available!",
GetName(),
fClassVersion, arena);
5198 p = { sinfo->
New(arena), sinfo };
5208 Error(
"New with placement",
"This cannot happen!");
5223 if (obj.GetPtr() && obj.GetAllocator()) {
5227 return obj.GetPtr();
5301 p = { sinfo->
NewArray(nElements), sinfo };
5311 Error(
"NewArray",
"This cannot happen!");
5325 if (obj.GetPtr() && obj.GetAllocator()) {
5329 return obj.GetPtr();
5351 Error(
"NewArray with placement",
"cannot create object of class %s version %d at address %p",
GetName(),
fClassVersion, arena);
5367 Error(
"NewArray with placement",
"cannot create object of class %s version %d at address %p",
GetName(),
fClassVersion, arena);
5396 Error(
"NewArray with placement",
"Cannot construct class '%s' version %d at address %p, no streamer info available!",
GetName(),
fClassVersion, arena);
5402 p = { sinfo->
NewArray(nElements, arena), sinfo };
5418 Error(
"NewArray with placement",
"This cannot happen!");
5430 if (obj ==
nullptr)
return;
5437 }
else if ((!dtorOnly) &&
fDelete) {
5480 objVer = iter->second;
5482 currentVersion =
kTRUE;
5489 if (!inRepo || currentVersion) {
5496 Error(
"Destructor",
"No streamer info available for class '%s' version %d at address %p, cannot destruct emulated object!",
GetName(),
fClassVersion, p);
5502 Error(
"Destructor",
"Doing Dump() ...");
5515 Error(
"Destructor",
"No streamer info available for class '%s' version %d, cannot destruct object at addr: %p",
GetName(), objVer, p);
5522 Error(
"Destructor2",
"Doing Dump() ...");
5533 Error(
"Destructor",
"This cannot happen! (class %s)",
GetName());
5543 if (obj.
GetPtr() ==
nullptr)
5559 if (ary ==
nullptr)
return;
5566 Error(
"DeleteArray",
"Destructor only is not supported!");
5605 objVer = iter->second;
5607 currentVersion =
kTRUE;
5614 if (!inRepo || currentVersion) {
5621 Error(
"DeleteArray",
"No streamer info available for class '%s' version %d at address %p, cannot destruct object!",
GetName(),
fClassVersion, ary);
5627 Error(
"DeleteArray",
"Doing Dump() ...");
5640 Error(
"DeleteArray",
"No streamer info available for class '%s' version %d at address %p, cannot destruct object!",
GetName(), objVer, ary);
5647 Error(
"DeleteArray",
"Doing Dump() ...");
5659 Error(
"DeleteArray",
"This cannot happen! (class '%s')",
GetName());
5669 if (obj.
GetPtr() ==
nullptr)
return;
5745 char *s =
new char[maxsize];
5749 b.ReadString(s, maxsize);
5750 while (strlen(s) == (maxsize - 1)) {
5752 b.SetBufferOffset(pos);
5753 maxsize = 2*maxsize;
5755 s =
new char[maxsize];
5756 b.ReadString(s, maxsize);
5761 ::Error(
"TClass::Load",
"dictionary of class %s not found", s);
5833 TIter next(
gROOT->GetListOfClassGenerators());
5860 bool autoParse = !
gInterpreter->IsAutoParsingSuspended();
5874 ::Error(
"TClass::LoadClassInfo",
"no interpreter information for class %s is available"
5875 " even though it has a TClass initialization routine.",
5901 const char *dfil,
const char *ifil,
5906 TMmallocDescTemp setreset;
5907 return new TClass(
cname,
id, info, isa, dfil, ifil, dl, il);
5915 const char *dfil,
const char *ifil,
5920 TMmallocDescTemp setreset;
6027 The class %s transitioned from not having a specified class version\n\
6028 to having a specified class version (the current class version is %d).\n\
6029 However too many different non-versioned layouts of the class have\n\
6030 already been loaded so far. To work around this problem you can\n\
6031 load fewer 'old' file in the same ROOT session or load the C++ library\n\
6032 describing the class %s before opening the files or increase the version\n\
6033 number of the class for example ClassDef(%s,%d).\n\
6034 Do not try to write objects with the current class definition,\n\
6035 the files might not be readable.\n",
6039 The StreamerInfo version %d for the class %s which was read\n\
6040 from a file previously opened has the same version as the active class\n\
6041 but a different checksum. You should update the version to ClassDef(%s,%d).\n\
6042 Do not try to write objects with the current class definition,\n\
6043 the files will not be readable.\n"
6054 if (strncmp(
GetName(),
"map<", 4) == 0)
6056 else if (strncmp(
GetName(),
"multimap<", 9) == 0)
6058 else if (strncmp(
GetName(),
"unordered_map<", 14) == 0)
6060 else if (strncmp(
GetName(),
"unordered_multimap<", 19) == 0)
6063 std::string pairname(
"pair");
6064 pairname.append(
GetName() + noffset);
6066 if ( pcl && !pcl->IsLoaded() && !pcl->IsSyntheticPair() )
6072 while (
auto acl = (
TClass*)nextClass()) {
6073 if (acl ==
this)
continue;
6074 if (acl->fCollectionProxy && acl->fCollectionProxy->GetValueClass() == pcl) {
6075 acl->fCollectionProxy->Reset();
6079 TIter next(pcl->GetStreamerInfos());
6081 if (info->IsBuilt()) {
6082 info->Clear(
"build");
6142 TMmallocDescTemp setreset;
6355 Fatal(
"SetUnloaded",
"The TClass for %s is being unloaded when in state %d\n",
6379 (*fMethod).Unload();
6385 (*fUsingData).Unload();
6484 //info is empty. Let's build the default Streamer descriptor
6486 char *temp = new char[10000];
6490 //add list of base classes
6491 TIter nextb(GetListOfBases());
6493 while ((base = (TBaseClass*) nextb())) {
6494 snprintf(local,100,"%s;",base->GetName());
6495 strlcat(temp,local,10000);
6498 //add list of data members and types
6499 TIter nextd(GetListOfDataMembers());
6500 while ((dm = (TDataMember *) nextd())) {
6501 if (dm->IsEnum()) continue;
6502 if (!dm->IsPersistent()) continue;
6503 Long_t property = dm->Property();
6504 if (property & kIsStatic) continue;
6505 TClass *acl = TClass::GetClass(dm->GetTypeName(),update);
6508 if (acl->GetClassVersion() == 0) continue;
6511 // dm->GetArrayIndex() returns an empty string if it does not
6513 const char * index = dm->GetArrayIndex();
6514 if (strlen(index)==0)
6515 snprintf(local,100,"%s %s;",dm->GetFullTypeName(),dm->GetName());
6517 snprintf(local,100,"%s %s[%s];",dm->GetFullTypeName(),dm->GetName(),index);
6518 strlcat(temp,local,10000);
6520 //fStreamerInfo = temp;
6609 for (
int i=0;
i<il;
i++)
id =
id*3+
name[
i];
6618 TIter nextBase(tlb);
6627 for (
int i=0;
i<il;
i++)
id =
id*3+
name[
i];
6630 Error(
"GetCheckSum",
"Calculating the checksum for (%s) requires the base class (%s) meta information to be available!",
6639 TList *tlm = ((
TClass*)
this)->GetListOfDataMembers();
6641 TIter nextMemb(tlm);
6657 for (
i=0;
i<il;
i++)
id =
id*3+
name[
i];
6669 type.ReplaceAll(
"ULong64_t",
"unsigned long long");
6670 type.ReplaceAll(
"Long64_t",
"long long");
6671 type.ReplaceAll(
"<signed char",
"<char");
6672 type.ReplaceAll(
",signed char",
",char");
6673 if (
type==
"signed char")
type =
"char";
6685 for (
i=0;
i<il;
i++)
id =
id*3+
type[
i];
6689 for (
int ii=0;ii<dim;ii++)
id =
id*3+tdm->
GetMaxIndex(ii);
6696 left = strstr(tdm->
GetTitle(),
"[");
6698 const char *right = strstr(left,
"]");
6701 while (left != right) {
6757 Error(
"AdoptMemberStreamer",
"Cannot adope member streamer for %s::%s",
GetName(),
name);
6796 return b.ReadClassBuffer(
this,pointer,version,start,count);
6805 return b.ReadClassBuffer(
this,pointer);
6817 b.WriteClassBuffer(
this,pointer);
6830 streamer->
Stream(
b,
object,onfile_class);
6862 if (
b.IsReading()) {
6863 b.ReadClassEmulated(pThis,
object, onfile_class);
6865 b.WriteClassBuffer(pThis,
object);
6896 if (
b.IsReading()) {
6897 b.ReadClassBuffer(pThis,
object, onfile_class);
6901 b.WriteClassBuffer(pThis,
object);
6920 pThis->
Fatal(
"StreamerDefault",
"fStreamerImpl not properly initialized (%d)", pThis->
fStreamerType);
7110 if (!info)
continue;
7151 std::map<std::string, TObjArray*>::iterator it;
7154 it = (*fConversionStreamerInfo).find( cl->
GetName() );
7156 if( it != (*fConversionStreamerInfo).end() ) {
7160 if( arr && version >= -1 && version < arr->GetSize() && arr->
At( version ) )
7172 if( version >= -1 && version < clSI->GetSize() )
7215 (*fConversionStreamerInfo)[cl->
GetName()] = arr;
7218 Error(
"GetConversionStreamerInfo",
"Conversion StreamerInfo from %s to %s version %d has already been created",
7259 std::map<std::string, TObjArray*>::iterator it;
7263 it = (*fConversionStreamerInfo).find( cl->
GetName() );
7265 if( it != (*fConversionStreamerInfo).end() ) {
7321 (*fConversionStreamerInfo)[cl->
GetName()] = arr;
7340 Error(
"RegisterStreamerInfo",
7341 "Register StreamerInfo for %s on non-empty slot (%d).",
7385 static const char *handVerified[] = {
7386 "TEnvRec",
"TDataType",
"TObjArray",
"TList",
"THashList",
7387 "TClass",
"TCling",
"TInterpreter",
"TMethod",
"ROOT::Internal::TCheckHashRecursiveRemoveConsistency",
7388 "TCheckHashRecursiveRemoveConsistency",
"TGWindow",
7389 "TDirectory",
"TDirectoryFile",
"TObject",
"TH1",
7390 "TQClass",
"TGlobal" };
7393 for (
auto cursor : handVerified) {
virtual RooAbsTestStatistic * create(const char *name, const char *title, RooAbsReal &real, RooAbsData &data, const RooArgSet &projDeps, Configuration const &cfg)=0
size_t size(const MatrixT &matrix)
retrieve the size of a square matrix
TClass *(* DictFuncPtr_t)()
void(* MemberStreamerFunc_t)(TBuffer &, void *, Int_t)
TClass *(* IsAGlobalFunc_t)(const TClass *, const void *obj)
void(* ClassStreamerFunc_t)(TBuffer &, void *)
void(* ClassConvStreamerFunc_t)(TBuffer &, void *, const TClass *)
R__EXTERN TClassTable * gClassTable
TClass::ENewType & TClass__GetCallingNew()
static bool IsFromRootCling()
ROOT::TMapDeclIdToTClass DeclIdMap_t
ROOT::TMapTypeToTClass IdMap_t
void(* tcling_callfunc_Wrapper_t)(void *, int, void **, void *)
return
Invalidate stored TCling state for declarations included in transaction ‘T’.
const Bool_t kIterBackward
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t cursor
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char filename
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h offset
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void data
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h prop
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t result
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize id
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char cname
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void value
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t Atom_t Atom_t Time_t UChar_t len
Option_t Option_t TPoint TPoint const char mode
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t Atom_t Atom_t Time_t type
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t Atom_t Atom_t Time_t property
Option_t Option_t TPoint TPoint const char text
R__EXTERN TVirtualMutex * gInterpreterMutex
R__EXTERN TInterpreter * gCling
externTVirtualMutex * gROOTMutex
void Printf(const char *fmt,...)
Formats a string in a circular formatting buffer and prints the string.
R__EXTERN TSystem * gSystem
R__EXTERN void **(* gThreadTsd)(void *, Int_t)
#define R__LOCKGUARD2(mutex)
#define R__LOCKGUARD(mutex)
#define R__WRITE_LOCKGUARD(mutex)
#define R__READ_LOCKGUARD(mutex)
Bool_t AddRule(TSchemaRule *rule, EConsistencyCheck checkConsistency=kCheckAll, TString *errmsg=nullptr)
The consistency check always fails if the TClass object was not set!
static bool Check(TClass &classRef)
A spin mutex-as-code-guard class.
DeclIdMap_t::key_type key_type
DeclIdMap_t::size_type size_type
multimap< TDictionary::DeclId_t, TClass * > DeclIdMap_t
size_type CountElementsWithKey(const key_type &key)
std::pair< const_iterator, const_iterator > equal_range
equal_range Find(const key_type &key) const
void Remove(const key_type &key)
DeclIdMap_t::const_iterator const_iterator
DeclIdMap_t::mapped_type mapped_type
void Add(const key_type &key, mapped_type obj)
mapped_type Find(const key_type &key) const
IdMap_t::size_type size_type
IdMap_t::mapped_type mapped_type
IdMap_t::const_iterator const_iterator
std::map< std::string, TClass * > IdMap_t
IdMap_t::key_type key_type
void Remove(const key_type &key)
void Add(const key_type &key, mapped_type &obj)
Bool_t SetFromRule(const char *rule)
Set the content fot this object from the rule See TClass::AddRule for details on the syntax.
const char * GetTargetString() const
Get the target data members of this rule as a simple string (i.e. the in memory data member).
const char * GetVersion() const
Get the version string.
const char * GetTargetClass() const
Get the targte class of this rule (i.e. the in memory class).
Bool_t IsTreatingNonAccessibleTypes() override
TAutoInspector(TBrowser *b)
virtual ~TAutoInspector()
void Inspect(TClass *cl, const char *parent, const char *name, const void *addr, Bool_t isTransient) override
This method is called from ShowMembers() via AutoBrowse().
Each class (see TClass) has a linked list of its base class(es).
Int_t GetDelta()
Get offset from "this" to part of base class.
ROOT::ESTLType IsSTLContainer()
Return which type (if any) of STL container the data member is.
Long_t Property() const override
Get property description word. For meaning of bits see EProperty.
TClass * GetClassPointer(Bool_t load=kTRUE)
Get pointer to the base class TClass.
Using a TBrowser one can browse all ROOT objects.
Buffer base class used for serializing objects.
void Inspect(TClass *cl, const char *parent, const char *name, const void *addr, Bool_t isTransient) override
This method is called from ShowMembers() via BuildRealdata().
TBuildRealData(void *obj, TClass *cl)
Objects following this interface can be passed onto the TROOT object to implement a user customized w...
virtual TClass * GetClass(const char *classname, Bool_t load)=0
TClassRef is used to implement a permanent reference to a TClass object.
virtual void Stream(TBuffer &b, void *objp, const TClass *onfileClass)
static DictFuncPtr_t GetDict(const char *cname)
Given the class name returns the Dictionary() function of a class (uses hash of name).
static TProtoClass * GetProtoNorm(const char *cname)
Given the class normalized name returns the TClassProto object for the class.
static DictFuncPtr_t GetDictNorm(const char *cname)
Given the normalized class name returns the Dictionary() function of a class (uses hash of name).
~InsertTClassInRegistryRAII()
TDeclNameRegistry & fNoInfoOrEmuOrFwdDeclNameRegistry
InsertTClassInRegistryRAII(TClass::EState &state, const char *name, TDeclNameRegistry &emuRegistry)
Bool_t HasDeclName(const char *name) const
std::unordered_set< std::string > fClassNamesSet
void AddQualifiedName(const char *name)
Extract this part of the name.
TDeclNameRegistry(Int_t verbLevel=0)
TDeclNameRegistry class constructor.
std::atomic_flag fSpinLock
TClass instances represent classes, structs and namespaces in the ROOT type system.
UInt_t GetCheckSum(ECheckSum code=kCurrentCheckSum) const
Call GetCheckSum with validity check.
Bool_t IsSyntheticPair() const
RepoCont_t fObjectVersionRepository
ShowMembersFunc_t fShowMembers
TDataMember * GetDataMember(const char *datamember) const
Return pointer to datamember object with name "datamember".
TList * GetListOfUsingDataMembers(Bool_t load=kTRUE)
Return list containing the TDataMembers of using declarations of a class.
void ForceReload(TClass *oldcl)
we found at least one equivalent.
ROOT::DelArrFunc_t fDeleteArray
Bool_t CanSplit() const
Return true if the data member of this TClass can be saved separately.
TClassStreamer * fStreamer
void SetDirectoryAutoAdd(ROOT::DirAutoAdd_t dirAutoAddFunc)
Install a new wrapper around the directory auto add function.
void * NewArray(Long_t nElements, ENewType defConstructor=kClassNew) const
Return a pointer to a newly allocated array of objects of this class.
static TDeclNameRegistry fNoInfoOrEmuOrFwdDeclNameRegistry
TListOfFunctionTemplates * fFuncTemplate
ClassStreamerFunc_t fStreamerFunc
void AdoptReferenceProxy(TVirtualRefProxy *proxy)
Adopt the Reference proxy pointer to indicate that this class represents a reference.
TMethod * GetClassMethod(Longptr_t faddr)
Look for a method in this class that has the interface function address faddr.
TVirtualStreamerInfo * DetermineCurrentStreamerInfo()
Determine and set pointer to current TVirtualStreamerInfo.
void Browse(TBrowser *b) override
This method is called by a browser to get the class information.
ROOT::ESTLType GetCollectionType() const
Return the 'type' of the STL the TClass is representing.
void Draw(Option_t *option="") override
Draw detailed class inheritance structure.
void AdoptMemberStreamer(const char *name, TMemberStreamer *strm)
Adopt the TMemberStreamer pointer to by p and use it to Stream non basic member name.
void ResetInstanceCount()
ClassStreamerFunc_t GetStreamerFunc() const
Get a wrapper/accessor function around this class custom streamer (member function).
void RemoveStreamerInfo(Int_t slot)
Remove and delete the StreamerInfo in the given slot.
void SetCanSplit(Int_t splitmode)
Set the splitability of this class:
TList * CreateListOfDataMembers(std::atomic< TListOfDataMembers * > &data, TDictionary::EMemberSelection selection, bool load)
Create the list containing the TDataMembers (of actual data members or members pulled in through usin...
TVirtualStreamerInfo * GetStreamerInfoAbstractEmulated(Int_t version=0) const
For the case where the requestor class is emulated and this class is abstract, returns a pointer to t...
void * New(ENewType defConstructor=kClassNew, Bool_t quiet=kFALSE) const
Return a pointer to a newly allocated object of this class.
void SetMerge(ROOT::MergeFunc_t mergeFunc)
Install a new wrapper around 'Merge'.
ConvSIMap_t fConversionStreamerInfo
ROOT::DirAutoAdd_t fDirAutoAdd
Bool_t HasDataMemberInfo() const
TVirtualRefProxy * fRefProxy
cached streamer info used in the last read.
TList * GetMenuList() const
Return the list of menu items associated with the class.
ROOT::MergeFunc_t fMerge
saved info to call a IsA member function
TMethod * GetMethod(const char *method, const char *params, Bool_t objectIsConst=kFALSE)
Find the best method (if there is one) matching the parameters.
static TClass * Load(TBuffer &b)
Load class description from I/O buffer and return class object.
EState fState
cached of the streaming method to use
ROOT::DesFunc_t GetDestructor() const
Return the wrapper around the destructor.
TMethod * GetMethodWithPrototype(const char *method, const char *proto, Bool_t objectIsConst=kFALSE, ROOT::EFunctionMatchMode mode=ROOT::kConversionMatch)
Find the method with a given prototype.
void CopyCollectionProxy(const TVirtualCollectionProxy &)
Replaces the collection proxy for this class.
Int_t fStreamerType
saved info to call Streamer
void ls(Option_t *opt="") const override
The ls function lists the contents of a class on stdout.
std::atomic< TList * > fBase
std::atomic< Char_t > fCanSplit
Bool_t HasDictionary() const
Check whether a class has a dictionary or not.
const TList * GetListOfAllPublicMethods(Bool_t load=kTRUE)
Returns a list of all public methods of this class and its base classes.
TList * GetListOfAllPublicDataMembers(Bool_t load=kTRUE)
Returns a list of all public data members of this class and its base classes.
TClass(const TClass &tc)=delete
static void AddClassToDeclIdMap(TDictionary::DeclId_t id, TClass *cl)
static: Add a TClass* to the map of classes.
virtual ~TClass()
TClass dtor. Deletes all list that might have been created.
Bool_t fIsSyntheticPair
Indicates whether this class can be split or not. Values are -1, 0, 1, 2.
void Destructor(void *obj, Bool_t dtorOnly=kFALSE)
Explicitly call destructor for object.
std::atomic< TVirtualStreamerInfo * > fCurrentInfo
Current 'state' of the class (Emulated,Interpreted,Loaded)
TList * GetListOfFunctionTemplates(Bool_t load=kTRUE)
Return TListOfFunctionTemplates for a class.
void * DynamicCast(const TClass *base, void *obj, Bool_t up=kTRUE)
Cast obj of this class type up to baseclass cl if up is true.
const char * fImplFileName
void RegisterStreamerInfo(TVirtualStreamerInfo *info)
Register the StreamerInfo in the given slot, change the State of the TClass as appropriate.
std::atomic< UInt_t > fCheckSum
void UnregisterAddressInRepository(const char *where, void *location, const TClass *what) const
std::atomic< TListOfFunctions * > fMethod
static void RemoveClassDeclId(TDictionary::DeclId_t id)
void SetNewArray(ROOT::NewArrFunc_t newArrayFunc)
Install a new wrapper around 'new []'.
Bool_t CallShowMembers(const void *obj, TMemberInspector &insp, Bool_t isTransient=kFALSE) const
Call ShowMembers() on the obj of this class type, passing insp and parent.
const char * fDeclFileName
void SetCollectionProxy(const ROOT::Detail::TCollectionProxyInfo &)
Create the collection proxy object (and the streamer object) from using the information in the TColle...
static Bool_t HasDictionarySelection(const char *clname)
Check whether a class has a dictionary or ROOT can load one.
void AdoptSchemaRules(ROOT::Detail::TSchemaRuleSet *rules)
Adopt a new set of Data Model Evolution rules.
static void StreamerInstrumented(const TClass *pThis, void *object, TBuffer &b, const TClass *onfile_class)
Case of instrumented class with a library.
TVirtualStreamerInfo * SetStreamerInfo(Int_t version, const char *info="")
Info is a string describing the names and types of attributes written by the class Streamer function.
static std::atomic< Int_t > fgClassCount
TVirtualStreamerInfo * GetCurrentStreamerInfo()
ROOT::DirAutoAdd_t GetDirectoryAutoAdd() const
Return the wrapper around the directory auto add function.
void AddImplFile(const char *filename, int line)
TCollection * GetListOfMethodOverloads(const char *name) const
Return the collection of functions named "name".
std::atomic< TListOfEnums * > fEnums
static Bool_t HasNoInfoOrEmuOrFwdDeclaredDecl(const char *)
TVirtualMutex * fOVRMutex
TList * GetListOfEnums(Bool_t load=kTRUE)
Return a list containing the TEnums of a class.
Bool_t IsStartingWithTObject() const
Returns true if this class inherits from TObject and if the start of the TObject parts is at the very...
TList * GetListOfMethods(Bool_t load=kTRUE)
Return list containing the TMethods of a class.
TClass()
Internal, default constructor.
Int_t GetNmethods()
Return the number of methods of this class Note that in case the list of methods is not yet created,...
std::atomic< Bool_t > fIsOffsetStreamerSet
Indicates whether the ClassInfo is supposed to be available.
void IgnoreTObjectStreamer(Bool_t ignore=kTRUE)
When the class kIgnoreTObjectStreamer bit is set, the automatically generated Streamer will not call ...
TClassStreamer * GetStreamer() const
Return the Streamer Class allowing streaming (if any).
static IdMap_t * GetIdMap()
void SetDelete(ROOT::DelFunc_t deleteFunc)
Install a new wrapper around 'delete'.
static Int_t AutoBrowse(TObject *obj, TBrowser *browser)
Browse external object inherited from TObject.
ROOT::NewFunc_t GetNew() const
Return the wrapper around new ThisClass().
TClass * GetBaseClass(const char *classname)
Return pointer to the base class "classname".
Longptr_t GetDataMemberOffset(const char *membername) const
return offset for member name.
Int_t GetNdata()
Return the number of data members of this class Note that in case the list of data members is not yet...
void SetDestructor(ROOT::DesFunc_t destructorFunc)
Install a new wrapper around the destructor.
virtual void PostLoadCheck()
Do the initialization that can only be done after the CINT dictionary has been fully populated and ca...
void LoadClassInfo() const
Try to load the ClassInfo if available.
void SetResetAfterMerge(ROOT::ResetAfterMergeFunc_t resetFunc)
Install a new wrapper around 'ResetAfterMerge'.
TVirtualStreamerInfo * GetStreamerInfoImpl(Int_t version, Bool_t silent) const
Bool_t MatchLegacyCheckSum(UInt_t checksum) const
Return true if the checksum passed as argument is one of the checksum value produced by the older che...
TViewPubFunctions * fAllPubMethod
Bool_t HasInterpreterInfo() const
static void AddClass(TClass *cl)
static: Add a class to the list and map of classes.
void GetMissingDictionariesForBaseClasses(TCollection &result, TCollection &visited, bool recurse)
Verify the base classes always.
ROOT::Detail::TSchemaRuleSet * fSchemaRules
Pointer to reference proxy if this class represents a reference.
std::atomic< Long_t > fProperty
static void StreamerDefault(const TClass *pThis, void *object, TBuffer &b, const TClass *onfile_class)
Default streaming in cases where either we have no way to know what to do or if Property() has not ye...
void SetUnloaded()
Call this method to indicate that the shared library containing this class's code has been removed (u...
ROOT::DelArrFunc_t GetDeleteArray() const
Return the wrapper around delete [] ThiObject.
Bool_t HasInterpreterInfoInMemory() const
ClassConvStreamerFunc_t fConvStreamerFunc
void BuildRealData(void *pointer=nullptr, Bool_t isTransient=kFALSE)
Build a full list of persistent data members.
void SetRuntimeProperties()
Internal routine to set calculate the class properties that can only be known at run-time,...
void BuildEmulatedRealData(const char *name, Longptr_t offset, TClass *cl, Bool_t isTransient=kFALSE)
Build the list of real data for an emulated class.
static TClass * LoadClass(const char *requestedname, Bool_t silent)
Helper function used by TClass::GetClass().
const std::type_info * GetTypeInfo() const
void SetStreamerImpl(Int_t streamerType)
Internal routine to set fStreamerImpl based on the value of fStreamerType.
TList * GetListOfDataMembers(Bool_t load=kTRUE)
Return list containing the TDataMembers of a class.
void Move(void *arenaFrom, void *arenaTo) const
Register the fact that an object was moved from the memory location 'arenaFrom' to the memory locatio...
static DeclIdMap_t * GetDeclIdMap()
Short_t GetDeclFileLine() const
void SetStreamerFunc(ClassStreamerFunc_t strm)
Set a wrapper/accessor function around this class custom streamer.
const char * GetImplFileName() const
TList * GetListOfRealData() const
Int_t Size() const
Return size of object of this class.
void SetCurrentStreamerInfo(TVirtualStreamerInfo *info)
Set pointer to current TVirtualStreamerInfo.
static DictFuncPtr_t GetDict(const char *cname)
Return a pointer to the dictionary loading function generated by rootcint.
Longptr_t fOffsetStreamer
Properties that can only be evaluated at run-time.
ROOT::NewArrFunc_t GetNewArray() const
Return the wrapper around new ThisClass[].
static void StreamerTObjectEmulated(const TClass *pThis, void *object, TBuffer &b, const TClass *onfile_class)
Case of TObjects when we do not have the library defining the class.
ROOT::ResetAfterMergeFunc_t GetResetAfterMerge() const
Return the wrapper around Merge.
TMethod * GetClassMethodWithPrototype(const char *name, const char *proto, Bool_t objectIsConst=kFALSE, ROOT::EFunctionMatchMode mode=ROOT::kConversionMatch)
Find the method with a given prototype.
Bool_t CanIgnoreTObjectStreamer()
void SetGlobalIsA(IsAGlobalFunc_t)
This function installs a global IsA function for this class.
void GetMissingDictionariesForMembers(TCollection &result, TCollection &visited, bool recurse)
Verify the Data Members.
TObjArray * fStreamerInfo
const ROOT::Detail::TSchemaRuleSet * GetSchemaRules() const
Return the set of the schema rules if any.
TObject * Clone(const char *newname="") const override
Create a Clone of this TClass object using a different name but using the same 'dictionary'.
TVirtualCollectionProxy * fCollectionProxy
static ENewType IsCallingNew()
Static method returning the defConstructor flag passed to TClass::New().
TList * GetListOfBases()
Return list containing the TBaseClass(es) of a class.
void Store(TBuffer &b) const
Store class description on I/O buffer.
void InterpretedShowMembers(void *obj, TMemberInspector &insp, Bool_t isTransient)
Do a ShowMembers() traversal of all members and base classes' members using the reflection informatio...
static THashTable * fgClassTypedefHash
void Init(const char *name, Version_t cversion, const std::type_info *info, TVirtualIsAProxy *isa, const char *dfil, const char *ifil, Int_t dl, Int_t il, ClassInfo_t *classInfo, Bool_t silent)
Initialize a TClass object.
std::atomic< TListOfDataMembers * > fData
static void StreamerStreamerInfo(const TClass *pThis, void *object, TBuffer &b, const TClass *onfile_class)
Case of where we should directly use the StreamerInfo.
const TObjArray * GetStreamerInfos() const
void SetClassVersion(Version_t version)
Private function.
char * EscapeChars(const char *text) const
Introduce an escape character (@) in front of a special chars.
const std::type_info * fTypeInfo
std::atomic< TVirtualStreamerInfo * > fLastReadInfo
cached current streamer info.
static void StreamerTObject(const TClass *pThis, void *object, TBuffer &b, const TClass *onfile_class)
Case of TObjects.
Bool_t IsLoaded() const
Return true if the shared library of this class is currently in the a process's memory.
static Bool_t AddRule(const char *rule)
Add a schema evolution customization rule.
Bool_t IsTObject() const
Return kTRUE is the class inherits from TObject.
static void RemoveClass(TClass *cl)
static: Remove a class from the list and map of classes
Bool_t HasLocalHashMember() const
Returns true if this class has an definition and/or overload of the member function Hash.
void DeleteArray(void *ary, Bool_t dtorOnly=kFALSE)
Explicitly call operator delete[] for an array.
ClassConvStreamerFunc_t GetConvStreamerFunc() const
Get a wrapper/accessor function around this class custom conversion streamer (member function).
Bool_t IsForeign() const
Return kTRUE is the class is Foreign (the class does not have a Streamer method).
ClassInfo_t * GetClassInfo() const
TViewPubDataMembers * fAllPubData
TVirtualStreamerInfo * GetStreamerInfo(Int_t version=0, Bool_t isTransient=kFALSE) const
returns a pointer to the TVirtualStreamerInfo object for version If the object does not exist,...
Bool_t HasConsistentHashMember()
Return 'true' if we can guarantee that if this class (or any class in this class inheritance hierarch...
void AdoptStreamer(TClassStreamer *strm)
Adopt a TClassStreamer object.
TClass * GetBaseDataMember(const char *datamember)
Return pointer to (base) class that contains datamember.
void Dump() const override
Dump contents of object on stdout.
Bool_t InheritsFrom(const char *cl) const override
Return kTRUE if this class inherits from a class with name "classname".
Int_t GetBaseClassOffset(const TClass *toBase, void *address=nullptr, bool isDerivedObject=true)
ObjectPtr NewObjectArray(Long_t nElements, ENewType defConstructor=kClassNew) const
Return a pointer to a newly allocated array of objects of this class.
TVirtualCollectionProxy * GetCollectionProxy() const
Return the proxy describing the collection (if any).
void ResetCaches()
To clean out all caches.
std::atomic< Bool_t > fVersionUsed
saved remember if fOffsetStreamer has been set.
Long_t ClassProperty() const
Return the C++ property of this class, eg.
const char * GetSharedLibs()
Get the list of shared libraries containing the code for class cls.
void CalculateStreamerOffset() const
Calculate the offset between an object of this class to its base class TObject.
void GetMissingDictionariesForPairElements(TCollection &result, TCollection &visited, bool recurse)
void ReplaceWith(TClass *newcl) const
void RegisterAddressInRepository(const char *where, void *location, const TClass *what) const
Long_t Property() const override
Returns the properties of the TClass as a bit field stored as a Long_t value.
Bool_t HasDefaultConstructor(Bool_t testio=kFALSE) const
Return true if we have access to a constructor usable for I/O.
void GetMenuItems(TList *listitems)
Returns list of methods accessible by context menu.
void SetNew(ROOT::NewFunc_t newFunc)
Install a new wrapper around 'new'.
std::atomic< TMethodCall * > fIsAMethod
static Int_t ReadRules()
Read the class.rules files from the default location:.
Bool_t CanSplitBaseAllow()
Pointer to the function implementing streaming for this class.
void MoveAddressInRepository(const char *where, void *oldadd, void *newadd, const TClass *what) const
std::atomic< StreamerImpl_t > fStreamerImpl
void SetContextMenuTitle(const char *title)
Change (i.e. set) the title of the TNamed.
void SetMemberStreamer(const char *name, MemberStreamerFunc_t strm)
Install a new member streamer (p will be copied).
std::atomic< TClass ** > fPersistentRef
IsAGlobalFunc_t fGlobalIsA
pointer to the class's IsA proxy.
TVirtualStreamerInfo * GetConversionStreamerInfo(const char *onfile_classname, Int_t version) const
Return a Conversion StreamerInfo from the class 'classname' for version number 'version' to this clas...
Short_t GetImplFileLine() const
TMethod * GetMethodAllAny(const char *method)
Return pointer to method without looking at parameters.
std::atomic< UChar_t > fRuntimeProperties
TVirtualStreamerInfo * FindConversionStreamerInfo(const char *onfile_classname, UInt_t checksum) const
Return a Conversion StreamerInfo from the class 'classname' for the layout represented by 'checksum' ...
Int_t GetBaseClassOffsetRecurse(const TClass *toBase)
Return data member offset to the base class "cl".
ROOT::DelFunc_t GetDelete() const
Return the wrapper around delete ThiObject.
static TClass * LoadClassDefault(const char *requestedname, Bool_t silent)
Helper function used by TClass::GetClass().
void SetClassSize(Int_t sizof)
TMethod * FindClassOrBaseMethodWithId(DeclId_t faddr)
Find a method with decl id in this class or its bases.
static void StreamerExternal(const TClass *pThis, void *object, TBuffer &b, const TClass *onfile_class)
There is special streamer for the class.
Long_t fClassProperty
Property See TClass::Property() for details.
TString fContextMenuTitle
static void StreamerTObjectInitialized(const TClass *pThis, void *object, TBuffer &b, const TClass *onfile_class)
Case of TObjects when fIsOffsetStreamerSet is known to have been set.
static void ConvStreamerInstrumented(const TClass *pThis, void *object, TBuffer &b, const TClass *onfile_class)
Case of instrumented class with a library.
std::atomic< Bool_t > fCanLoadClassInfo
Whether info was loaded from a root pcm.
void SetConvStreamerFunc(ClassConvStreamerFunc_t strm)
Set a wrapper/accessor function around this class custom conversion streamer.
TVirtualStreamerInfo * FindStreamerInfo(TObjArray *arr, UInt_t checksum) const
Find the TVirtualStreamerInfo in the StreamerInfos corresponding to checksum.
void GetMissingDictionaries(THashTable &result, bool recurse=false)
Get the classes that have a missing dictionary starting from this one.
void MakeCustomMenuList()
Makes a customizable version of the popup menu list, i.e.
TVirtualStreamerInfo * FindStreamerInfoAbstractEmulated(UInt_t checksum) const
For the case where the requestor class is emulated and this class is abstract, returns a pointer to t...
TMethod * GetMethodAny(const char *method)
Return pointer to method without looking at parameters.
TVirtualIsAProxy * GetIsAProxy() const
Return the proxy implementing the IsA functionality.
ROOT::MergeFunc_t GetMerge() const
Return the wrapper around Merge.
ROOT::ResetAfterMergeFunc_t fResetAfterMerge
Bool_t IsFolder() const override
Returns kTRUE in case object contains browsable objects (like containers or lists of other objects).
std::atomic< Bool_t > fHasRootPcmInfo
C++ Property of the class (is abstract, has virtual table, etc.)
TClass * GetActualClass(const void *object) const
Return a pointer to the real class of the object.
ROOT::DesFunc_t fDestructor
const char * GetDeclFileName() const
Return name of the file containing the declaration of this class.
ObjectPtr NewObject(ENewType defConstructor=kClassNew, Bool_t quiet=kFALSE) const
TRealData * GetRealData(const char *name) const
Return pointer to TRealData element with name "name".
void SetDeleteArray(ROOT::DelArrFunc_t deleteArrayFunc)
Install a new wrapper around 'delete []'.
Bool_t fHasCustomStreamerMember
The class has a Streamer method and it is implemented by the user or an older (not StreamerInfo based...
TFunctionTemplate * GetFunctionTemplate(const char *name)
void ResetClassInfo()
Make sure that the current ClassInfo is up to date.
ROOT::NewArrFunc_t fNewArray
Int_t ReadBuffer(TBuffer &b, void *pointer, Int_t version, UInt_t start, UInt_t count)
Function called by the Streamer functions to deserialize information from buffer b into object at p.
void GetMissingDictionariesWithRecursionCheck(TCollection &result, TCollection &visited, bool recurse)
From the second level of recursion onwards it is different state check.
bool IsClassStructOrUnion() const
std::atomic< TListOfDataMembers * > fUsingData
TListOfFunctions * GetMethodList()
Return (create an empty one if needed) the list of functions.
void ResetMenuList()
Resets the menu list to it's standard value.
static TClass * GetClass(const char *name, Bool_t load=kTRUE, Bool_t silent=kFALSE)
Static method returning pointer to TClass of the specified class name.
Int_t WriteBuffer(TBuffer &b, void *pointer, const char *info="")
Function called by the Streamer functions to serialize object at p to buffer b.
static TClass * LoadClassCustom(const char *requestedname, Bool_t silent)
Helper function used by TClass::GetClass().
Collection abstract base class.
void ls(Option_t *option="") const override
List (ls) all objects in this collection.
virtual void Add(TObject *obj)=0
TObject * FindObject(const char *name) const override
Find an object in this collection using its name.
virtual Int_t GetSize() const
Return the capacity of the collection, i.e.
All ROOT classes may have RTTI (run time type identification) support added.
Int_t GetMaxIndex(Int_t dim) const
Return maximum index for array dimension "dim".
const char * GetTrueTypeName() const
Get the desugared type name of this data member, including const and volatile qualifiers.
Bool_t IsPersistent() const
Long_t Property() const override
Get property description word. For meaning of bits see EProperty.
Int_t GetArrayDim() const
Return number of array dimensions.
Bool_t IsBasic() const
Return true if data member is a basic type, e.g. char, int, long...
Bool_t IsaPointer() const
Return true if data member is a pointer.
TDataType * GetDataType() const
const char * GetTypeName() const
const char * GetFullTypeName() const
Get the concrete type name of this data member, including const and volatile qualifiers.
Basic data type descriptor (datatype information is obtained from CINT).
Long_t Property() const override
Get property description word. For meaning of bits see EProperty.
const char * AsString(void *buf) const
Return string containing value in buffer formatted according to the basic data type.
TString GetTypeName()
Get basic type of typedef, e,g.: "class TDirectory*" -> "TDirectory".
static TDataType * GetDataType(EDataType type)
Given a EDataType type, get the TDataType* that represents it.
static void GetDateTime(UInt_t datetime, Int_t &date, Int_t &time)
Static function that returns the date and time.
EMemberSelection
Kinds of members to include in lists.
void Inspect(TClass *cl, const char *parent, const char *name, const void *addr, Bool_t isTransient) override
Print value of member mname.
TDumpMembers(bool noAddr)
static TEnum * GetEnum(const std::type_info &ti, ESearchAction sa=kALoadAndInterpLookup)
Long64_t GetValue(ULong64_t hash, Long64_t key)
Return the value belonging to specified key and hash value.
void AddAt(UInt_t slot, ULong64_t hash, Long64_t key, Long64_t value)
Add an (key,value) pair to the table.
Dictionary for function template This class describes one single function template.
Global functions class (global functions are obtained from CINT).
Int_t GetNargs() const
Number of function arguments.
THashTable implements a hash table to store TObject's.
void Add(TObject *obj) override
Add object to the hash table.
TDictionary::DeclId_t DeclId_t
TIsAProxy implementation class.
A collection of TDataMember objects designed for fast access given a DeclId_t and for keep track of T...
A collection of TEnum objects designed for fast access given a DeclId_t and for keep track of TEnum t...
A collection of TEnum objects designed for fast access given a DeclId_t and for keep track of TEnum t...
A collection of TFunction objects designed for fast access given a DeclId_t and for keep track of TFu...
A collection of TFunction objects designed for fast access given a DeclId_t and for keep track of TFu...
TFunction * Get(DeclId_t id)
Return (after creating it if necessary) the TMethod or TFunction describing the function correspondin...
virtual TList * GetListForObject(const char *name) const
Return the set of overloads for this name, collecting all available ones.
TObject * FindObject(const TObject *obj) const override
Find object using its hash value (returned by its Hash() member).
void Add(TObject *obj) override
virtual TObjLink * FirstLink() const
void Delete(Option_t *option="") override
Remove all objects from the list AND delete all heap based objects.
TMap implements an associative array of (key,value) pairs using a THashTable for efficient retrieval ...
Abstract base class for accessing the data-members of a class.
TMemberInspector(const TMemberInspector &)=delete
virtual void Inspect(TClass *cl, const char *parent, const char *name, const void *addr)
EObjectPointerState GetObjectValidity() const
Each ROOT method (see TMethod) has a linked list of its arguments.
const char * GetFullTypeName() const
Get full type description of method argument, e.g.: "class TDirectory*".
Each ROOT class (see TClass) has a linked list of methods.
TClass * GetClass() const
EMenuItemKind IsMenuItem() const
virtual TList * GetListOfMethodArgs()
Returns methodarg list and additionally updates fDataMember in TMethod by calling FindDataMember();.
TObject * Clone(const char *newname="") const override
Make a clone of an object using the Streamer facility.
virtual void SetTitle(const char *title="")
Set the title of the TNamed.
const char * GetName() const override
Returns name of object.
const char * GetTitle() const override
Returns title of object.
virtual void SetName(const char *name)
Set the name of the TNamed.
void ls(Option_t *option="") const override
List TNamed name and title.
Int_t GetEntriesFast() const
void Clear(Option_t *option="") override
Remove all objects from the array.
virtual void AddAtAndExpand(TObject *obj, Int_t idx)
Add object at position idx.
TObject * At(Int_t idx) const override
TObject * UncheckedAt(Int_t i) const
TObject * FindObject(const char *name) const override
Find an object in this collection using its name.
Int_t GetLast() const override
Return index of last object in array.
Wrapper around a TObject so it can be stored in a TList.
TObject * GetObject() const
Collectable string class.
Mother of all ROOT objects.
static void SetObjectStat(Bool_t stat)
Turn on/off tracking of objects in the TObjectTable.
virtual const char * GetName() const
Returns name of object.
virtual void Browse(TBrowser *b)
Browse object. May be overridden for another default action.
R__ALWAYS_INLINE Bool_t TestBit(UInt_t f) const
virtual void Streamer(TBuffer &)
Stream an object of class TObject.
virtual void Warning(const char *method, const char *msgfmt,...) const
Issue warning message.
virtual TObject * FindObject(const char *name) const
Must be redefined in derived classes.
R__ALWAYS_INLINE Bool_t IsZombie() const
void SetBit(UInt_t f, Bool_t set)
Set or unset the user status bits as specified in f.
static Bool_t GetObjectStat()
Get status of object stat flag.
virtual void Error(const char *method, const char *msgfmt,...) const
Issue error message.
virtual void Fatal(const char *method, const char *msgfmt,...) const
Issue fatal error message.
virtual void SetUniqueID(UInt_t uid)
Set the unique object id.
virtual TClass * IsA() const
TObject()
TObject constructor.
virtual void Info(const char *method, const char *msgfmt,...) const
Issue info message.
static const TString & GetEtcDir()
Get the sysconfig directory in the installation. Static utility function.
The TRealData class manages the effective list of all data members for a given class.
const char * GetName() const override
Returns name of object.
void AdoptStreamer(TMemberStreamer *p)
Long_t GetThisOffset() const
void SetIsObject(Bool_t isObject)
TClass * GetClassPointer() const override
Returns a pointer to the TClass of this element.
virtual const char * GetFullName() const
Return element name including dimensions, if any Note that this function stores the name into a stati...
virtual TClass * GetClassPointer() const
Returns a pointer to the TClass of this element.
Int_t GetArrayDim() const
virtual Bool_t IsaPointer() const
const char * GetTypeName() const
TClass * IsA() const override
virtual Bool_t IsBase() const
Return kTRUE if the element represent a base class.
TString & Replace(Ssiz_t pos, Ssiz_t n, const char *s)
const char * Data() const
TString & ReplaceAll(const TString &s1, const TString &s2)
UInt_t Hash(ECaseCompare cmp=kExact) const
Return hash value.
TString & Remove(Ssiz_t pos)
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString.
void Form(const char *fmt,...)
Formats a string using a printf style format descriptor.
Bool_t Contains(const char *pat, ECaseCompare cmp=kExact) const
Ssiz_t Index(const char *pat, Ssiz_t i=0, ECaseCompare cmp=kExact) const
View implementing the TList interface and giving access all the TDictionary describing public data me...
View implementing the TList interface and giving access all the TFunction describing public methods i...
RAII helper class that ensures that PushProxy() / PopProxy() are called when entering / leaving a C++...
Defines a common interface to inspect/change the contents of an object that represents a collection.
virtual Int_t GetProperties() const
Return miscallenous properties of the proxy (see TVirtualCollectionProxy::EProperty)
virtual void Destructor(void *p, Bool_t dtorOnly=kFALSE) const
Execute the container destructor.
virtual void DeleteArray(void *p, Bool_t dtorOnly=kFALSE) const
Execute the container array destructor.
virtual TClass * GetValueClass() const =0
If the value type is a user-defined class, return a pointer to the TClass representing the value type...
virtual void * At(UInt_t idx)=0
Return the address of the value at index idx
virtual UInt_t Size() const =0
Return the current number of elements in the container.
virtual TVirtualCollectionProxy * Generate() const =0
Returns a clean object of the actual class that derives from TVirtualCollectionProxy.
virtual Bool_t HasPointers() const =0
Return true if the content is of type 'pointer to'.
This class implements a mutex interface.
small helper class to store/restore gPad context in TPad methods
TVirtualPad is an abstract base class for the Pad and Canvas classes.
virtual TVirtualPad * cd(Int_t subpadnumber=0)=0
Abstract Interface class describing Streamer information for one class.
virtual TVirtualStreamerInfo * GenerateInfoForPair(const std::string &pairclassname, bool silent, size_t hint_pair_offset, size_t hint_pair_size)=0
Generate the TClass and TStreamerInfo for the requested pair.
virtual void DeleteArray(void *p, Bool_t dtorOnly=kFALSE)=0
virtual void Clear(Option_t *="") override=0
Set name and title to empty strings ("").
virtual void SetClassVersion(Int_t vers)=0
virtual TClassStreamer * GenEmulatedClassStreamer(const char *class_name, Bool_t silent)=0
Bool_t IsCompiled() const
virtual TVirtualStreamerInfo * NewInfo(TClass *cl)=0
virtual TClass * GetActualClass(const void *obj) const =0
virtual UInt_t GetCheckSum() const =0
virtual Int_t GetOffset(const char *) const =0
static const char * GetElementCounterStart(const char *dmTitle)
Given a comment/title declaring an array counter, for example:
virtual void Build(Bool_t isTransient=kFALSE)=0
virtual void BuildCheck(TFile *file=nullptr, Bool_t load=kTRUE)=0
virtual Bool_t BuildFor(const TClass *cl)=0
virtual TVirtualCollectionProxy * GenExplicitProxy(const ::ROOT::Detail::TCollectionProxyInfo &info, TClass *cl)=0
virtual void * NewArray(Long_t nElements, void *ary=nullptr)=0
virtual TVirtualCollectionProxy * GenEmulatedProxy(const char *class_name, Bool_t silent)=0
virtual void SetClass(TClass *cl)=0
virtual TObjArray * GetElements() const =0
virtual Int_t GetSize() const =0
virtual void BuildOld()=0
static TVirtualStreamerInfo * Factory()
Static function returning a pointer to a new TVirtualStreamerInfo object.
virtual void * New(void *obj=nullptr)=0
virtual Version_t GetOldVersion() const =0
virtual Int_t GetOnFileClassVersion() const =0
virtual void Destructor(void *p, Bool_t dtorOnly=kFALSE)=0
virtual Bool_t CompareContent(TClass *cl, TVirtualStreamerInfo *info, Bool_t warn, Bool_t complete, TFile *file)=0
virtual Int_t GetClassVersion() const =0
virtual void Update(const TClass *oldClass, TClass *newClass)=0
virtual TClass * GetClass() const =0
R__EXTERN void * gMmallocDesc
Bool_t HasConsistentHashMember(TClass &clRef)
Return true is the Hash/RecursiveRemove setup is consistent, i.e.
tbb::task_arena is an alias of tbb::interface7::task_arena, which doesn't allow to forward declare tb...
void(* DirAutoAdd_t)(void *, TDirectory *)
R__EXTERN TVirtualRWMutex * gCoreMutex
void(* ResetAfterMergeFunc_t)(void *, TFileMergeInfo *)
void(* DesFunc_t)(void *)
TClass * CreateClass(const char *cname, Version_t id, const std::type_info &info, TVirtualIsAProxy *isa, const char *dfil, const char *ifil, Int_t dl, Int_t il)
Global function called by a class' static Dictionary() method (see the ClassDef macro).
void(* DelFunc_t)(void *)
void *(* NewArrFunc_t)(Long_t size, void *arena)
void Class_ShowMembers(TClass *cl, const void *obj, TMemberInspector &)
Indirect call to the implementation of ShowMember allowing [forward] declaration with out a full defi...
void(* DelArrFunc_t)(void *)
void *(* NewFunc_t)(void *)
Long64_t(* MergeFunc_t)(void *, TCollection *, TFileMergeInfo *)
bool IsStdPairBase(std::string_view name)
std::string ResolveTypedef(const char *tname, bool resolveAll=false)
bool IsStdArray(std::string_view name)
bool IsStdClass(const char *type)
return true if the class belongs to the std namespace
bool IsStdPair(std::string_view name)
bool IsInterpreterDetail(const char *type)
Return true if the type is one the interpreter details which are only forward declared (ClassInfo_t e...
char * DemangleTypeIdName(const std::type_info &ti, int &errorCode)
Demangle in a portable way the type id name.
ROOT::ESTLType IsSTLCont(std::string_view type)
type : type name: vector<list<classA,allocator>,allocator> result: 0 : not stl container code of cont...
std::string ShortType(const char *typeDesc, int mode)
Return the absolute type of typeDesc.
bool IsArtificial(std::string_view name)
void GetNormalizedName(std::string &norm_name, std::string_view name)
Return the normalized name.
bool IsSTLBitset(const char *type)
Return true is the name is std::bitset<number> or bitset<number>
UInt_t Find(std::list< std::pair< const Node< T > *, Float_t > > &nlist, const Node< T > *node, const T &event, UInt_t nfind)
Short_t Min(Short_t a, Short_t b)
Returns the smallest of a and b.
TMatrixT< Element > & Add(TMatrixT< Element > &target, Element scalar, const TMatrixT< Element > &source)
Modify addition: target += scalar * source.
bool IsTemplate()
Check if the type is a template.
std::vector< std::string > fElements
TVirtualStreamerInfo * GetAllocator() const
TClass::ENewType & fCurrentValue
TClass__GetCallingNewRAII(TClass::ENewType newvalue)
TClass::ENewType fOldValue
~TClass__GetCallingNewRAII()