40 gROOT->GetListOfCleanups()->Add(
this);
43 if (fixMustCleanupBit) {
47 Error(
"TObjectSpy",
"spied object must have the kMustCleanup bit set");
60 gROOT->GetListOfCleanups()->Remove(
this);
87 if (fixMustCleanupBit) {
91 Error(
"TObjectSpy",
"spied object must have the kMustCleanup bit set");
103 fObj(obj), fResetMustCleanupBit(
kFALSE)
107 gROOT->GetListOfCleanups()->Add(
this);
110 if (fixMustCleanupBit) {
114 Error(
"TObjectSpy",
"spied object must have the kMustCleanup bit set");
127 gROOT->GetListOfCleanups()->Remove(
this);
R__EXTERN TVirtualMutex * gROOTMutex
#define R__LOCKGUARD(mutex)
TObjectRefSpy(const TObjectRefSpy &s)=delete
virtual ~TObjectRefSpy()
Cleanup.
Bool_t fResetMustCleanupBit
virtual void RecursiveRemove(TObject *obj)
Sets the object pointer to zero if the object is deleted in the RecursiveRemove() operation.
Monitors objects for deletion and reflects the deletion by reverting the internal pointer to zero.
Bool_t fResetMustCleanupBit
virtual ~TObjectSpy()
Cleanup.
TObjectSpy(const TObjectSpy &s)=delete
void SetObject(TObject *obj, Bool_t fixMustCleanupBit=kTRUE)
Set obj as the spy target.
virtual void RecursiveRemove(TObject *obj)
Sets the object pointer to zero if the object is deleted in the RecursiveRemove() operation.
Mother of all ROOT objects.
R__ALWAYS_INLINE Bool_t TestBit(UInt_t f) const
void SetBit(UInt_t f, Bool_t set)
Set or unset the user status bits as specified in f.
virtual void Error(const char *method, const char *msgfmt,...) const
Issue error message.
@ kMustCleanup
if object destructor must call RecursiveRemove()