/* /% C++ %/ */ /*********************************************************************** * cint (C/C++ interpreter) ************************************************************************ * Header file Class.h ************************************************************************ * Description: * Extended Run Time Type Identification API ************************************************************************ * Copyright(c) 1995~1998 Masaharu Goto * * For the licensing terms see the file COPYING * ************************************************************************/ #ifndef G__CLASSINFO_H #define G__CLASSINFO_H #ifndef G__API_H #include "Api.h" #endif namespace Cint { class G__MethodInfo; class G__DataMemberInfo; class G__FriendInfo; /********************************************************************* * class G__ClassInfo * * *********************************************************************/ class #ifndef __CINT__ G__EXPORT #endif G__ClassInfo { public: virtual ~G__ClassInfo() {} G__ClassInfo(): tagnum(0), class_property(0) { Init(); } void Init(); G__ClassInfo(const char *classname): tagnum(0), class_property(0){ Init(classname); } void Init(const char *classname); G__ClassInfo(const G__value &value_for_type); G__ClassInfo(int tagnumin): tagnum(0), class_property(0) { Init(tagnumin); } void Init(int tagnumin); int operator==(const G__ClassInfo& a); int operator!=(const G__ClassInfo& a); const char *Name() ; const char *Fullname(); const char *Title() ; int Size() ; long Property(); int NDataMembers(); int NMethods(); long IsBase(const char *classname); long IsBase(G__ClassInfo& a); void* DynamicCast(G__ClassInfo& to, void* obj); int Tagnum() const { return(tagnum); } G__ClassInfo EnclosingClass() ; G__ClassInfo EnclosingSpace() ; struct G__friendtag* GetFriendInfo(); void SetGlobalcomp(G__SIGNEDCHAR_T globalcomp); void SetProtectedAccess(int protectedaccess); #ifdef G__OLDIMPLEMENTATION1218_YET int IsValid() { return 0<=tagnum && tagnumtagnum); else cls.Init(-1); } G__ClassInfo* FriendOf() { return(&cls); } int Next() { if(pfriendtag) { pfriendtag=pfriendtag->next; Init(pfriendtag); return(IsValid()); } else { return(0); } } int IsValid() { if(pfriendtag) return(1); else return(0); } private: G__friendtag *pfriendtag; G__ClassInfo cls; }; } // namespace Cint using namespace Cint; #endif