ROOT logo
ROOT » ROOFIT » ROOFITCORE » RooExpensiveObjectCache

class RooExpensiveObjectCache: public TObject



RooExpensiveObjectCache is a singleton class that serves as repository for objects that are expensive to calculate. Owners of such objects can registers these here with associated parameter values for which the object is valid, so that other instances can, at a later moment retrieve these precalculated objects

Function Members (Methods)

public:
RooExpensiveObjectCache()
RooExpensiveObjectCache(const RooExpensiveObjectCache&)
virtual~RooExpensiveObjectCache()
voidTObject::AbstractMethod(const char* method) const
virtual voidTObject::AppendPad(Option_t* option = "")
virtual voidTObject::Browse(TBrowser* b)
static TClass*Class()
virtual const char*TObject::ClassName() const
static voidcleanup()
virtual voidTObject::Clear(Option_t* = "")
voidclearAll()
Bool_tclearObj(Int_t uniqueID)
virtual TObject*TObject::Clone(const char* newname = "") const
virtual Int_tTObject::Compare(const TObject* obj) const
virtual voidTObject::Copy(TObject& object) const
virtual voidTObject::Delete(Option_t* option = "")MENU
virtual Int_tTObject::DistancetoPrimitive(Int_t px, Int_t py)
virtual voidTObject::Draw(Option_t* option = "")
virtual voidTObject::DrawClass() constMENU
virtual TObject*TObject::DrawClone(Option_t* option = "") constMENU
virtual voidTObject::Dump() constMENU
virtual voidTObject::Error(const char* method, const char* msgfmt) const
virtual voidTObject::Execute(const char* method, const char* params, Int_t* error = 0)
virtual voidTObject::Execute(TMethod* method, TObjArray* params, Int_t* error = 0)
virtual voidTObject::ExecuteEvent(Int_t event, Int_t px, Int_t py)
virtual voidTObject::Fatal(const char* method, const char* msgfmt) const
virtual TObject*TObject::FindObject(const char* name) const
virtual TObject*TObject::FindObject(const TObject* obj) const
virtual Option_t*TObject::GetDrawOption() const
static Long_tTObject::GetDtorOnly()
virtual const char*TObject::GetIconName() const
virtual const char*TObject::GetName() const
const TObject*getObj(Int_t uniqueID)
virtual char*TObject::GetObjectInfo(Int_t px, Int_t py) const
static Bool_tTObject::GetObjectStat()
virtual Option_t*TObject::GetOption() const
virtual const char*TObject::GetTitle() const
virtual UInt_tTObject::GetUniqueID() const
virtual Bool_tTObject::HandleTimer(TTimer* timer)
virtual ULong_tTObject::Hash() const
voidimportCacheObjects(RooExpensiveObjectCache& other, const char* ownerName, Bool_t verbose = kFALSE)
virtual voidTObject::Info(const char* method, const char* msgfmt) const
virtual Bool_tTObject::InheritsFrom(const char* classname) const
virtual Bool_tTObject::InheritsFrom(const TClass* cl) const
virtual voidTObject::Inspect() constMENU
static RooExpensiveObjectCache&instance()
voidTObject::InvertBit(UInt_t f)
virtual TClass*IsA() const
virtual Bool_tTObject::IsEqual(const TObject* obj) const
virtual Bool_tTObject::IsFolder() const
Bool_tTObject::IsOnHeap() const
virtual Bool_tTObject::IsSortable() const
Bool_tTObject::IsZombie() const
virtual voidTObject::ls(Option_t* option = "") const
voidTObject::MayNotUse(const char* method) const
virtual Bool_tTObject::Notify()
static voidTObject::operator delete(void* ptr)
static voidTObject::operator delete(void* ptr, void* vp)
static voidTObject::operator delete[](void* ptr)
static voidTObject::operator delete[](void* ptr, void* vp)
void*TObject::operator new(size_t sz)
void*TObject::operator new(size_t sz, void* vp)
void*TObject::operator new[](size_t sz)
void*TObject::operator new[](size_t sz, void* vp)
RooExpensiveObjectCache&operator=(const RooExpensiveObjectCache&)
virtual voidTObject::Paint(Option_t* option = "")
virtual voidTObject::Pop()
voidprint() const
virtual voidTObject::Print(Option_t* option = "") const
virtual Int_tTObject::Read(const char* name)
virtual voidTObject::RecursiveRemove(TObject* obj)
Bool_tregisterObject(const char* ownerName, const char* objectName, TObject& cacheObject, TIterator* paramIter)
Bool_tregisterObject(const char* ownerName, const char* objectName, TObject& cacheObject, const RooArgSet& params)
voidTObject::ResetBit(UInt_t f)
const TObject*retrieveObject(const char* name, TClass* tclass, const RooArgSet& params)
virtual voidTObject::SaveAs(const char* filename = "", Option_t* option = "") constMENU
virtual voidTObject::SavePrimitive(basic_ostream<char,char_traits<char> >& out, Option_t* option = "")
voidTObject::SetBit(UInt_t f)
voidTObject::SetBit(UInt_t f, Bool_t set)
virtual voidTObject::SetDrawOption(Option_t* option = "")MENU
static voidTObject::SetDtorOnly(void* obj)
Bool_tsetObj(Int_t uniqueID, TObject* obj)
static voidTObject::SetObjectStat(Bool_t stat)
virtual voidTObject::SetUniqueID(UInt_t uid)
virtual voidShowMembers(TMemberInspector& insp, char* parent)
Int_tsize() const
virtual voidStreamer(TBuffer& b)
voidStreamerNVirtual(TBuffer& b)
virtual voidTObject::SysError(const char* method, const char* msgfmt) const
Bool_tTObject::TestBit(UInt_t f) const
Int_tTObject::TestBits(UInt_t f) const
virtual voidTObject::UseCurrentStyle()
virtual voidTObject::Warning(const char* method, const char* msgfmt) const
virtual Int_tTObject::Write(const char* name = 0, Int_t option = 0, Int_t bufsize = 0)
virtual Int_tTObject::Write(const char* name = 0, Int_t option = 0, Int_t bufsize = 0) const
protected:
virtual voidTObject::DoError(int level, const char* location, const char* fmt, va_list va) const
voidTObject::MakeZombie()

Data Members

protected:
static RooExpensiveObjectCache*_instance!
map<TString,ExpensiveObject*>_map
Int_t_nextUID

Class Charts

Inheritance Inherited Members Includes Libraries
Class Charts

Function documentation

RooExpensiveObjectCache()
 Constructor
RooExpensiveObjectCache(const RooExpensiveObjectCache& )
 Copy constructor
~RooExpensiveObjectCache()
 Destructor.
RooExpensiveObjectCache& instance()
 Return reference to singleton instance
void cleanup()
 Static function called by RooSentinel atexit() handler to cleanup at end of program
Bool_t registerObject(const char* ownerName, const char* objectName, TObject& cacheObject, const RooArgSet& params)
 Register object associated with given name and given associated parameters with given values in cache.
 The cache will take _ownership_of_object_ and is indexed under the given name (which does not
 need to be the name of cacheObject and with given set of dependent parameters with validity for the
 current values of those parameters. It can be retrieved later by callin retrieveObject()
Bool_t registerObject(const char* ownerName, const char* objectName, TObject& cacheObject, TIterator* parIter)
 Register object associated with given name and given associated parameters with given values in cache.
 The cache will take _ownership_of_object_ and is indexed under the given name (which does not
 need to be the name of cacheObject and with given set of dependent parameters with validity for the
 current values of those parameters. It can be retrieved later by callin retrieveObject()
const TObject* retrieveObject(const char* name, TClass* tclass, const RooArgSet& params)
 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.
 The return object is owned by the cache instance.
const TObject* getObj(Int_t uniqueID)
 Retrieve payload object of cache element with given unique ID
Bool_t clearObj(Int_t uniqueID)
 Clear cache element with given unique ID
 Retrieve payload object of cache element with given unique ID
Bool_t setObj(Int_t uniqueID, TObject* obj)
 Place new payload object in cache element with given unique ID. Cache
 will take ownership of provided object!
void clearAll()
 Clear all cache elements
void print() const
void importCacheObjects(RooExpensiveObjectCache& other, const char* ownerName, Bool_t verbose = kFALSE)
Int_t size() const
{ return _map.size() ; }