/usr/include/root/TVirtualObject.h is in libroot-io-dev 5.34.14-1build1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 | // @(#)root/io:$Id$
// Author: Philippe Canal July, 2008
/*************************************************************************
* Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
* All rights reserved. *
* *
* For the licensing terms see $ROOTSYS/LICENSE. *
* For the list of contributors see $ROOTSYS/README/CREDITS. *
*************************************************************************/
#ifndef ROOT_TVirtualObject
#define ROOT_TVirtualObject
//////////////////////////////////////////////////////////////////////////
// //
// TVirtualObject //
// //
// Wrapper around an object and giving indirect access to its content //
// even if the object is not of a class in the Cint/Reflex dictionary. //
// //
//////////////////////////////////////////////////////////////////////////
#ifndef ROOT_TClassRef
#include "TClassRef.h"
#endif
class TVirtualObject {
private:
TVirtualObject(const TVirtualObject&); // not implemented
TVirtualObject &operator=(const TVirtualObject&); // not implemented
public:
TClassRef fClass;
void *fObject;
TVirtualObject(TClass *cl) : fClass(cl), fObject(cl ? cl->New() : 0) { }
~TVirtualObject() { if (fClass) fClass->Destructor(fObject); }
TClass *GetClass() const { return fClass; }
void *GetObject() const { return fObject; }
};
#endif // ROOT_TVirtualObject
|