126 if (buf && ( (
fMode&
kWrite)!=0 ) && fBufSize < 0) {
198 if (buf && ( (
fMode&
kWrite)!=0 ) && fBufSize < 0) {
214 if ( (l > newsize) && copy ) {
226 Fatal(
"Expand",
"Failed to expand the data buffer using TStorage::ReAllocChar.");
228 Fatal(
"Expand",
"Failed to expand the data buffer because TBuffer does not own it and no custom memory reallocator was provided.");
230 Fatal(
"Expand",
"Failed to expand the data buffer using custom memory reallocator 0x%lx.", (
Long_t)
fReAllocFunc);
static TProcessID * GetPID()
static: returns pointer to current TProcessID
virtual Int_t WriteClassBuffer(const TClass *cl, void *pointer)=0
virtual ~TBuffer()
Delete an I/O buffer object.
TObject * GetParent() const
Return pointer to parent of this buffer.
ReAllocCharFun_t fReAllocFunc
char *(* ReAllocCharFun_t)(char *, size_t, size_t)
Buffer base class used for serializing objects.
R__ALWAYS_INLINE Bool_t TestBit(UInt_t f) const
void SetParent(TObject *parent)
Set parent owning this buffer.
void SetBit(UInt_t f, Bool_t set)
Set or unset the user status bits as specified in f.
virtual TProcessID * ReadProcessID(UShort_t pidf)=0
Return the current Process-ID.
static char * ReAllocChar(char *vp, size_t size, size_t oldsize)
Reallocate (i.e.
static TClass * GetClass(const std::type_info &typeinfo)
Forward to TROOT::GetClass().
static char * R__NoReAllocChar(char *, size_t, size_t)
The user has provided memory than we don't own, thus we can not extent it either. ...
A TProcessID identifies a ROOT job in a unique way in time and space.
virtual UShort_t WriteProcessID(TProcessID *pid)=0
Always return 0 (current processID).
void Expand(Int_t newsize, Bool_t copy=kTRUE)
Expand (or shrink) the I/O buffer to newsize bytes.
CacheList_t fCacheStack
Realloc function to be used when extending the buffer.
Wrapper around an object and giving indirect access to its content even if the object is not of a cla...
virtual TVirtualArray * PeekDataCache() const
Return the 'current' data cache area from the list of area to be used for temporarily store 'missing'...
void SetReadMode()
Set buffer in read mode.
The ROOT global object gROOT contains a list of all defined classes.
virtual Int_t ReadClassBuffer(const TClass *cl, void *pointer, const TClass *onfile_class=0)=0
virtual TVirtualArray * PopDataCache()
Pop and Return the 'current' data cache area from the list of area to be used for temporarily store '...
ReAllocCharFun_t GetReAllocFunc() const
Return the reallocation method currently used.
virtual void PushDataCache(TVirtualArray *)
Push a new data cache area onto the list of area to be used for temporarily store 'missing' data memb...
static TClass * GetClass(const char *name, Bool_t load=kTRUE, Bool_t silent=kFALSE)
Static method returning pointer to TClass of the specified class name.
Mother of all ROOT objects.
virtual void Fatal(const char *method, const char *msgfmt,...) const
Issue fatal error message.
void SetReAllocFunc(ReAllocCharFun_t reallocfunc=0)
Set which memory reallocation method to use.
void DefaultStreamer(TBuffer &R__b, const TClass *cl, void *objpointer)
Default streamer implementation used by ClassDefInline to avoid requirement to include TBuffer...
void AutoExpand(Int_t size_needed)
Automatically calculate a new size and expand the buffer to fit at least size_needed.
void SetWriteMode()
Set buffer in write mode.
void SetBuffer(void *buf, UInt_t bufsiz=0, Bool_t adopt=kTRUE, ReAllocCharFun_t reallocfunc=0)
Sets a new buffer in an existing TBuffer object.