#include <RootType.h>
|
| void | Init (const std::string &name, Bool_t load, Bool_t quiet) |
Definition at line 119 of file RootType.h.
◆ TScopeAdapter() [1/6]
| TScopeAdapter::TScopeAdapter |
( |
| ) |
|
◆ TScopeAdapter() [2/6]
| TScopeAdapter::TScopeAdapter |
( |
TClass * | klass | ) |
|
◆ TScopeAdapter() [3/6]
| TScopeAdapter::TScopeAdapter |
( |
const std::string & | name, |
|
|
Bool_t | load = kTRUE ) |
Definition at line 500 of file RootType.cxx.
500 :
502{
503 Init (name, load,
false);
504}
void Init(const std::string &name, Bool_t load, Bool_t quiet)
◆ TScopeAdapter() [4/6]
| TScopeAdapter::TScopeAdapter |
( |
const std::string & | name, |
|
|
Bool_t | load, |
|
|
Bool_t | quiet ) |
◆ TScopeAdapter() [5/6]
Definition at line 571 of file RootType.cxx.
571 :
574{
575
576}
const double mb
1mb to cm2
◆ TScopeAdapter() [6/6]
| TScopeAdapter::TScopeAdapter |
( |
const std::type_info & | typeinfo | ) |
|
Definition at line 550 of file RootType.cxx.
551 :
fClass (TClassRef( TClass::GetClass(typeinfo) ) )
552{
554
555
556
557 if (!
fClass.GetClass()->HasDictionary()) {
558 fClass = TClassRef( TClass::GetClass(typeinfo) );
559 }
561 } else {
563 size_t len =
sizeof(
buff);
565 fName = __cxxabiv1::__cxa_demangle(typeinfo.name(), buff, &len, &status);
567 }
568}
◆ ATLAS_NOT_THREAD_SAFE()
| TScopeAdapter ByName TScopeAdapter::ATLAS_NOT_THREAD_SAFE |
( |
const std::string & | name, |
|
|
Bool_t | load = kTRUE, |
|
|
Bool_t | quiet = kTRUE ) |
|
static |
◆ BaseAt()
Definition at line 778 of file RootType.cxx.
779{
780
781 return (TBaseClass*)
fClass->GetListOfBases()->At( nth );
782}
◆ BaseSize()
| size_t TScopeAdapter::BaseSize |
( |
| ) |
const |
Definition at line 754 of file RootType.cxx.
755{
756
757 if (
fClass.GetClass() &&
fClass->GetListOfBases() != 0 )
758 return fClass->GetListOfBases()->GetSize();
759
760 return 0;
761}
◆ ByNameNoQuiet()
| TScopeAdapter TScopeAdapter::ByNameNoQuiet |
( |
const std::string & | name, |
|
|
Bool_t | load = kTRUE ) |
|
static |
◆ Class()
| TClass * TScopeAdapter::Class |
( |
| ) |
const |
|
inline |
◆ Construct() [1/2]
| void * TScopeAdapter::Construct |
( |
| ) |
const |
◆ Construct() [2/2]
| void * RootType::Construct |
( |
void * | place | ) |
const |
◆ DataMemberAt()
Definition at line 812 of file RootType.cxx.
813{
814
815 return (TDataMember*)
fClass->GetListOfDataMembers()->At( nth );
816}
◆ DataMemberSize()
| size_t TScopeAdapter::DataMemberSize |
( |
| ) |
const |
Definition at line 802 of file RootType.cxx.
803{
804
806 return fClass->GetListOfDataMembers()->GetSize();
807
808 return 0;
809}
◆ DeclaringScope()
Definition at line 655 of file RootType.cxx.
656{
658 std::string::size_type
pos =
name.rfind(
"::" );
659 if ( pos == std::string::npos )
661 TClass::GetClass( gInterpreter->ClassInfo_Factory( "" ) ) );
663}
◆ Destruct()
| void TScopeAdapter::Destruct |
( |
void * | place | ) |
const |
◆ EnableCintex()
| void TScopeAdapter::EnableCintex |
( |
| ) |
|
|
inlinestatic |
◆ FunctionMemberAt()
Definition at line 795 of file RootType.cxx.
796{
797
798 return (TMethod*)
fClass->GetListOfMethods()->At( nth );
799}
◆ FunctionMemberSize()
| size_t TScopeAdapter::FunctionMemberSize |
( |
| ) |
const |
Definition at line 785 of file RootType.cxx.
786{
787
789 return fClass->GetListOfMethods()->GetSize();
790
791 return 0;
792}
◆ Id()
| void * TScopeAdapter::Id |
( |
| ) |
const |
|
inline |
◆ Init()
| void TScopeAdapter::Init |
( |
const std::string & | name, |
|
|
Bool_t | load, |
|
|
Bool_t | quiet ) |
|
private |
Definition at line 519 of file RootType.cxx.
520{
521 const string anonnmsp("(anonymous)");
522
523 if( !load ) {
524
526 if( klass ) {
528 return;
529 }
530 } else {
531
533 fClass = TClassRef( scoped_name.c_str() );
535 return;
536 }
537 }
538
539
540 if( gROOT->GetType(
name.c_str()) ) {
542 }
else if( TEnum::GetEnum(
name.c_str(), load ? TEnum::kALoadAndInterpLookup : TEnum::kNone) ) {
543
545 }
546}
◆ IsAbstract()
| Bool_t TScopeAdapter::IsAbstract |
( |
| ) |
const |
Definition at line 954 of file RootType.cxx.
955{
956
958 return fClass->Property() & kIsAbstract;
959
960 return kFALSE;
961}
◆ IsArray()
| Bool_t TScopeAdapter::IsArray |
( |
| ) |
const |
◆ IsClass()
| Bool_t TScopeAdapter::IsClass |
( |
| ) |
const |
Definition at line 916 of file RootType.cxx.
917{
918
919 if (
fClass.GetClass() ) {
920
921
922 return (
fClass->Property() & kIsClass) || ! (
fClass->Property() & kIsFundamental);
923 }
924
925
926
928}
◆ IsComplete()
| Bool_t TScopeAdapter::IsComplete |
( |
| ) |
const |
Definition at line 895 of file RootType.cxx.
896{
897
900 TClass*
klass = TClass::GetClass( scname.c_str(),
true,
true );
901
902 if ( klass) {
903 b =
klass->HasDictionary();
904 }
905 else {
906 ClassInfo_t* ci = gInterpreter->ClassInfo_Factory( scname.c_str() );
907 if ( ci ) {
908 b = gInterpreter->ClassInfo_IsLoaded( ci );
909 gInterpreter->ClassInfo_Delete( ci );
910 }
911 }
913}
◆ IsEnum()
| Bool_t TScopeAdapter::IsEnum |
( |
| ) |
const |
◆ IsFundamental()
| Bool_t TScopeAdapter::IsFundamental |
( |
| ) |
const |
◆ IsNamespace()
| Bool_t TScopeAdapter::IsNamespace |
( |
| ) |
const |
Definition at line 944 of file RootType.cxx.
945{
946
948 return fClass->Property() & kIsNamespace;
949
950 return kFALSE;
951}
◆ IsPointer()
| Bool_t TScopeAdapter::IsPointer |
( |
| ) |
const |
◆ IsStruct()
| Bool_t TScopeAdapter::IsStruct |
( |
| ) |
const |
Definition at line 931 of file RootType.cxx.
932{
933
934 if (
fClass.GetClass() ) {
935
936 return (
fClass->Property() & kIsStruct) || ! (
fClass->Property() & kIsFundamental);
937 }
938
939
941}
◆ IsTemplateInstance()
| Bool_t TScopeAdapter::IsTemplateInstance |
( |
| ) |
const |
Definition at line 710 of file RootType.cxx.
711{
712
713
714
716 return kTRUE;
717
719 return kTRUE;
720
721 return kFALSE;
722}
std::string Name(unsigned int mod=Reflex::SCOPED) const
std::string find(const std::string &s)
return a remapped string
◆ IsTopScope()
| Bool_t TScopeAdapter::IsTopScope |
( |
| ) |
const |
Definition at line 725 of file RootType.cxx.
726{
727
728 return fClass->GetClassInfo() == gInterpreter->ClassInfo_Factory(
"" );
729}
◆ IsTypedef()
| Bool_t TScopeAdapter::IsTypedef |
( |
| ) |
const |
Definition at line 743 of file RootType.cxx.
744{
745 return fClass.GetClass()?
fClass.GetClass()->Property() & kIsTypedef :
false;
746}
◆ Name()
| std::string TScopeAdapter::Name |
( |
unsigned int | mod = Reflex::SCOPED | ) |
const |
Definition at line 612 of file RootType.cxx.
613{
614
616
618
621
624
626 }
627
631
633
634 Int_t tpl_open = 0;
635 for ( std::string::size_type pos =
name.size() - 1; 0 < pos; --pos ) {
636 std::string::value_type
c =
name[
pos ];
637
638
639 if ( c == '>' )
640 ++tpl_open;
641 else if ( c == '<' )
642 --tpl_open;
643 else if ( tpl_open == 0 && c == ':' && 0 < pos && name[ pos-1 ] == ':' ) {
644
645 name =
name.substr( pos+1, std::string::npos );
646 break;
647 }
648 }
649 }
650
652}
static const std::string ResolveTypedef(const std::string &tname)
static const std::string UnqualifiedTypeName(const std::string &name)
◆ operator Bool_t()
| TScopeAdapter::operator Bool_t |
( |
| ) |
const |
Definition at line 879 of file RootType.cxx.
880{
881
882 if(
fName.empty() )
return false;
884
885
887 if( !klass ) return false;
888 if(
klass->HasDictionary() )
return true;
889
890
891 return false;
892}
◆ operator TClass *()
| TScopeAdapter::operator TClass * |
( |
| ) |
const |
|
inline |
◆ operator!=()
Definition at line 190 of file RootType.h.
190 {
191 return ! (*this == rh);
192 }
◆ operator<()
◆ operator==()
◆ Properties()
◆ SizeOf()
| size_t TScopeAdapter::SizeOf |
( |
| ) |
const |
Definition at line 765 of file RootType.cxx.
766{
768 return fClass.GetClass()->Size();
769 } else {
770 const TDataType* fundType = gROOT->GetType(
fName.c_str());
771 if ( fundType )
772 return fundType->Size();
773 }
774 return 0;
775}
◆ TemplateArgumentAt()
| TScopeAdapter TScopeAdapter::TemplateArgumentAt |
( |
size_t | nth | ) |
const |
Definition at line 819 of file RootType.cxx.
820{
821
822
824 size_t tpl_open = 0, argcount = 0;
825 std::string::size_type last = 0;
826 for ( std::string::size_type pos = 0;
pos <
name.size(); ++
pos ) {
827 std::string::value_type
c =
name[
pos];
828
829
830 if ( c == '<' ) {
831 ++tpl_open;
832 if (tpl_open == 1) last =
pos+1;
833 continue;
834 } else if (c == '>' && tpl_open > 0) {
835 --tpl_open;
836 }
837 if ((c == ',' && tpl_open == 1) || (c == '>' && tpl_open == 0)) {
838 if ( argcount++ == nth ) {
839
840
841
842 R__WRITE_LOCKGUARD(ROOT::gCoreMutex);
844 TClassEdit::CleanType(
name.substr(last, pos-last).c_str(), 1 );
846 }
848 }
849 }
850
851
852 assert( !"miscount between TemplateArgumentSize() and TemplateArgumentAt()" );
854}
◆ TemplateArgumentSize()
| size_t TScopeAdapter::TemplateArgumentSize |
( |
| ) |
const |
Definition at line 857 of file RootType.cxx.
858{
859
861 size_t tpl_open = 0, argcount = 0;
862 for ( std::string::size_type pos = 0;
pos <
name.size(); ++
pos ) {
863 std::string::value_type
c =
name[
pos];
864
865
866 if ( c == '<' ) {
867 ++tpl_open;
868 continue;
869 } else if ( c == '>' && tpl_open > 0 )
870 --tpl_open;
871
872 if ((c == ',' && tpl_open == 1) || (c == '>' && tpl_open == 0))
873 ++argcount;
874 }
875 return argcount;
876}
◆ ToType()
◆ TypeAt()
Definition at line 593 of file RootType.cxx.
594{
595 R__READ_LOCKGUARD (ROOT::gCoreMutex);
596 const char *
class_name = gClassTable->At( nth );
597
599}
◆ TypeInfo()
| const type_info & TScopeAdapter::TypeInfo |
( |
| ) |
const |
Definition at line 684 of file RootType.cxx.
685{
688 }
689 return *
fClass.GetClass()->GetTypeInfo();
690}
const std::type_info & fundamental_type(const std::string &name)
◆ TypeOf()
◆ TypeSize()
| size_t TScopeAdapter::TypeSize |
( |
| ) |
|
|
static |
Definition at line 602 of file RootType.cxx.
603{
604
605
606 R__READ_LOCKGUARD (ROOT::gCoreMutex);
608 return tab ? tab->Classes() : 0;
609}
#define ATLAS_THREAD_SAFE
◆ fClass
| TClassRef TScopeAdapter::fClass |
|
private |
◆ fIsFundamental
| bool TScopeAdapter::fIsFundamental = false |
|
private |
◆ fName
| std::string TScopeAdapter::fName |
|
private |
The documentation for this class was generated from the following files: