16 #ifndef ROO_EXPENSIVE_OBJECT_CACHE 17 #define ROO_EXPENSIVE_OBJECT_CACHE 85 std::map<TString,ExpensiveObject*>
_map ;
void clearAll()
Clear all cache elements.
static RooExpensiveObjectCache * _instance
virtual ~ExpensiveObject()
Bool_t clearObj(Int_t uniqueID)
Clear cache element with given unique ID Retrieve payload object of cache element with given unique I...
static void cleanup()
Static function called by RooSentinel atexit() handler to cleanup at end of program.
Bool_t matches(TClass *tc, const RooArgSet ¶ms)
Check object type ;.
RooExpensiveObjectCache is a singleton class that serves as repository for objects that are expensive...
std::map< TString, Int_t > _catRefParams
std::map< TString, ExpensiveObject * > _map
virtual ~RooExpensiveObjectCache()
Destructor.
const TObject * retrieveObject(const char *name, TClass *tclass, const RooArgSet ¶ms)
Retrieve object from cache that was registered under given name with given parameters, if current parameter values match those that were stored in the registry for this object.
Iterator abstract base class.
#define ClassDef(name, id)
const TObject * payload() const
void importCacheObjects(RooExpensiveObjectCache &other, const char *ownerName, Bool_t verbose=kFALSE)
std::map< TString, Double_t > _realRefParams
const char * ownerName() const
The ROOT global object gROOT contains a list of all defined classes.
RooExpensiveObjectCache()
Constructor.
Bool_t setObj(Int_t uniqueID, TObject *obj)
Place new payload object in cache element with given unique ID.
static RooExpensiveObjectCache & instance()
Return reference to singleton instance.
Mother of all ROOT objects.
const TObject * getObj(Int_t uniqueID)
Retrieve payload object of cache element with given unique ID.
Bool_t registerObject(const char *ownerName, const char *objectName, TObject &cacheObject, TIterator *paramIter)
Register object associated with given name and given associated parameters with given values in cache...
void setPayload(TObject *obj)
const char * Data() const