80 void operator delete(
void *vp);
#define ClassDef(name, id)
Using a TBrowser one can browse all ROOT objects.
Describe directory structure in memory.
This class implements a shared memory region mapped to a file.
static TMapFile * WhichMapFile(void *addr)
static Long_t fgMapAddress
Map to this address, set address via SetMapAddress()
void * GetBreakval() const
Return the current location in the memory region for this malloc heap which represents the end of mem...
Int_t fWritten
Number of objects written sofar.
static TMapFile * Create(const char *name, Option_t *option="READ", Int_t size=kDefaultMapSize, const char *title="")
Create a memory mapped file.
TMapRec * fLast
Last object in list of shared objects.
Int_t fVersion
ROOT version (or -1 for shadow map file)
const char * GetOption() const
TObject * Remove(TObject *obj)
Int_t fSemaphore
Modification semaphore (or getpid() for WIN32)
Long_t fOffset
Offset in bytes for region mapped by reader.
void Close(Option_t *option="")
Close a mapped file.
TDirectory * fDirectory
Pointer to directory associated to this mapfile.
void SumBuffer(Int_t bufsize)
Increment statistics for buffer sizes of objects in this file.
void Update(TObject *obj=0)
Update an object (or all objects, if obj == 0) in shared memory.
void * GetMmallocDesc() const
TObject * Get(const char *name, TObject *retObj=nullptr)
Return pointer to object retrieved from shared memory.
void * GetBaseAddr() const
ULong_t fhSemaphore
HANDLE of WIN32 Mutex object to implement semaphore.
char * fTitle
Title of mapped file.
void InitDirectory()
Create the directory associated to this mapfile.
TMapRec * GetLast() const
Bool_t IsWritable() const
TMapFile & operator=(const TMapFile &rhs)=delete
void RemoveAll()
Remove all objects from shared memory.
Double_t fSum2Buffer
Sum of squares of buffer sizes of objects written so far.
Bool_t fWritable
TRUE if mapped file opened in RDWR mode.
void * OrgAddress(void *addr) const
Bool_t IsFolder() const
Returns kTRUE in case object is a folder (i.e. contains browsable lists).
void DeleteSemaphore()
Delete the semaphore.
TList * fBrowseList
List of KeyMapFile objects.
TMapRec * fFirst
List of streamed objects is shared memory.
Int_t fFd
Descriptor of mapped file.
static void * MapToAddress()
Return the base address at which we would like the next TMapFile's mapped data to start.
TObject * fGetting
Don't deadlock in update mode, when from Get() Add() is called.
TMapFile * FindShadowMapFile()
Returns shadow map file.
void Browse(TBrowser *b)
Browse contents of TMapFile.
void ls(Option_t *option="") const
List contents of TMapFile.
void * fMmallocDesc
Pointer to mmalloc descriptor.
Double_t fSumBuffer
Sum of buffer sizes of objects written sofar.
static void * fgMmallocDesc
Used in Close() and operator delete()
TDirectory * GetDirectory() const
void CreateSemaphore(Int_t pid=0)
Create semaphore used for synchronizing access to shared memory.
Int_t fSize
Original start size of memory mapped region.
TObject * Remove(TObject *obj, Bool_t lock)
Remove object from shared memory.
Int_t ReleaseSemaphore()
Release semaphore. Returns 0 if OK, -1 on error.
static void SetMapAddress(Long_t addr)
Set preferred map address.
ULong_t fBaseAddr
Base address of mapped memory region.
char * fName
Name of mapped file.
Bool_t cd(const char *path=0)
Cd to associated directory.
TMapFile()
Default ctor. Does not much except setting some basic values.
char * fOption
Directory creation options.
Int_t AcquireSemaphore()
Acquire semaphore. Returns 0 if OK, -1 on error.
const char * GetName() const
Returns name of object.
TObject * Remove(const char *name)
void Add(const TObject *obj, const char *name="")
Add an object to the list of objects to be stored in shared memory.
virtual ~TMapFile()
TMapFiles may not be deleted, since we want to keep the complete TMapFile object in the mapped file f...
const char * GetTitle() const
Returns title of object.
void Print(Option_t *option="") const
Print some info about the mapped file.
Int_t GetBestBuffer()
Return the best buffer size for objects in this file.
TMapRec * GetFirst() const
Keep track of an object in the mapped file.
TObject * fObject
Pointer to original object.
TMapRec & operator=(const TMapRec &)=delete
const char * GetClassName(Long_t offset=0) const
Int_t fBufSize
Buffer size.
TMapRec(const TMapRec &)=delete
TMapRec * fNext
Next MapRec in list.
TMapRec * GetNext(Long_t offset=0) const
TObject * GetObject() const
This method returns a pointer to the original object.
void * GetBuffer(Long_t offset=0) const
char * fClassName
Class name.
const char * GetName(Long_t offset=0) const
void * fBuffer
Buffer containing object of class name.
Mother of all ROOT objects.