#ifdef __cplusplus extern "C" { #endif #ifndef __HROOT_CORE__TObject__ #define __HROOT_CORE__TObject__ #include "HROOT-coreType.h" #include "HROOTCoreDeletable.h" #undef TOBJECT_DECL_VIRT #define TOBJECT_DECL_VIRT(Type) \ void Type ## _Draw ( Type ## _p p, const char* option ); \ TObject_p Type ## _FindObject ( Type ## _p p, const char* name ); \ const char* Type ## _GetName ( Type ## _p p ); \ TClass_p Type ## _IsA ( Type ## _p p ); \ void Type ## _Paint ( Type ## _p p, const char* option ); \ void Type ## _printObj ( Type ## _p p, const char* option ); \ void Type ## _SaveAs ( Type ## _p p, const char* filename, const char* option ); \ int Type ## _Write ( Type ## _p p, const char* name, int option, int bufsize ) #undef TOBJECT_DECL_NONVIRT #define TOBJECT_DECL_NONVIRT(Type) \ Type ## _p Type ## _newTObject ( ); \ int Type ## _tObjectGetObjectStat ( ) #undef TOBJECT_DEF_VIRT #define TOBJECT_DEF_VIRT(Type)\ void Type ## _Draw ( Type ## _p p, const char* option )\ {\ TYPECASTMETHOD(Type,Draw,TObject)(p)->Draw(option);\ }\ TObject_p Type ## _FindObject ( Type ## _p p, const char* name )\ {\ return to_nonconst((TObject*)TYPECASTMETHOD(Type,FindObject,TObject)(p)->FindObject(name));\ }\ const char* Type ## _GetName ( Type ## _p p )\ {\ return TYPECASTMETHOD(Type,GetName,TObject)(p)->GetName();\ }\ TClass_p Type ## _IsA ( Type ## _p p )\ {\ return to_nonconst((TClass*)TYPECASTMETHOD(Type,IsA,TObject)(p)->IsA());\ }\ void Type ## _Paint ( Type ## _p p, const char* option )\ {\ TYPECASTMETHOD(Type,Paint,TObject)(p)->Paint(option);\ }\ void Type ## _printObj ( Type ## _p p, const char* option )\ {\ TYPECASTMETHOD(Type,printObj,TObject)(p)->Print(option);\ }\ void Type ## _SaveAs ( Type ## _p p, const char* filename, const char* option )\ {\ TYPECASTMETHOD(Type,SaveAs,TObject)(p)->SaveAs(filename, option);\ }\ int Type ## _Write ( Type ## _p p, const char* name, int option, int bufsize )\ {\ return TYPECASTMETHOD(Type,Write,TObject)(p)->Write(name, option, bufsize);\ } #undef TOBJECT_DEF_NONVIRT #define TOBJECT_DEF_NONVIRT(Type)\ Type ## _p Type ## _newTObject ( )\ {\ Type * newp = new Type (); \ return to_nonconst(newp);\ }\ int Type ## _tObjectGetObjectStat ( )\ {\ return TObject::GetObjectStat();\ } DELETABLE_DECL_VIRT(TObject); TOBJECT_DECL_VIRT(TObject); TOBJECT_DECL_NONVIRT(TObject); #endif // __HROOT_CORE__TObject__ #ifdef __cplusplus } #endif